Example #1
0
 public Decimal256Array(ArrayData data)
     : base(ArrowTypeId.Decimal256, data)
 {
     data.EnsureDataType(ArrowTypeId.Decimal256);
     data.EnsureBufferCount(2);
     Debug.Assert(Data.DataType is Decimal256Type);
 }
Example #2
0
        public DictionaryArray(ArrayData data) : base(data)
        {
            data.EnsureBufferCount(2);
            data.EnsureDataType(ArrowTypeId.Dictionary);

            if (data.Dictionary == null)
            {
                throw new ArgumentException($"{nameof(data.Dictionary)} must not be null");
            }

            var dicType = (DictionaryType)data.DataType;

            data.Dictionary.EnsureDataType(dicType.ValueType.TypeId);

            var indicesData = new ArrayData(dicType.IndexType, data.Length, data.NullCount, data.Offset, data.Buffers, data.Children);

            Indices    = ArrowArrayFactory.BuildArray(indicesData);
            Dictionary = ArrowArrayFactory.BuildArray(data.Dictionary);
        }
Example #3
0
 public BinaryArray(ArrowTypeId typeId, ArrayData data)
     : base(data)
 {
     data.EnsureDataType(typeId);
     data.EnsureBufferCount(3);
 }
Example #4
0
 private ListArray(ArrayData data, IArrowArray values) : base(data)
 {
     data.EnsureBufferCount(2);
     data.EnsureDataType(ArrowTypeId.List);
     Values = values;
 }
Example #5
0
 protected PrimitiveArray(ArrayData data)
     : base(data)
 {
     data.EnsureBufferCount(2);
 }
Example #6
0
 public UnionArray(ArrayData data)
     : base(data)
 {
     data.EnsureDataType(ArrowTypeId.Union);
     data.EnsureBufferCount(3);
 }
Example #7
0
 public ListArray(ArrayData data)
     : base(data)
 {
     data.EnsureBufferCount(2);
     data.EnsureDataType(ArrowTypeId.List);
 }