Exemplo n.º 1
0
        public ListEncoder(Column column)
        {
            _getFunc = column.GetFunction;

            Debug.Assert(column.Children.Count == 1);

            var child = column.Children.First();

            _childEncoder = EncoderHelper.GetEncoder(child);
        }
Exemplo n.º 2
0
        public ObjectEncoder(Column column)
        {
            _getFunc = column.GetFunction;

            _childEncoders = new IJsonEncoder[column.Children.Count];
            _names         = new JsonEncodedText[column.Children.Count];

            for (int i = 0; i < column.Children.Count; i++)
            {
                _childEncoders[i] = EncoderHelper.GetEncoder(column.Children[i]);
                _names[i]         = JsonEncodedText.Encode(column.Children[i].Name);
            }
        }