Class Decimal128Array
public class Decimal128Array : FixedSizeBinaryArray, IArrowArray, IDisposable, IReadOnlyList<byte[]>, IReadOnlyCollection<byte[]>, IEnumerable<byte[]>, IReadOnlyList<SqlDecimal?>, IReadOnlyCollection<SqlDecimal?>, IEnumerable<SqlDecimal?>, IEnumerable
- Inheritance
-
Decimal128Array
- Implements
-
IEnumerable<byte[]>
- Inherited Members
Constructors
Decimal128Array(ArrayData)
public Decimal128Array(ArrayData data)
Parameters
dataArrayData
Properties
ByteWidth
public int ByteWidth { get; }
Property Value
Precision
public int Precision { get; }
Property Value
Scale
public int Scale { get; }
Property Value
Methods
Accept(IArrowArrayVisitor)
public override void Accept(IArrowArrayVisitor visitor)
Parameters
visitorIArrowArrayVisitor
GetSqlDecimal(int)
public SqlDecimal? GetSqlDecimal(int index)
Parameters
indexint
Returns
GetString(int)
public string GetString(int index)
Parameters
indexint
Returns
GetValue(int)
Gets the decimal value at the index of the array. May throw an exception if the value can't be expressed as a decimal. See TryGetValue(int, out decimal?) for details.
public decimal? GetValue(int index)
Parameters
indexint
Returns
ToList(bool)
public IList<decimal?> ToList(bool includeNulls = false)
Parameters
includeNullsbool
Returns
TryGetValue(int, out decimal?)
Gets the decimal value at the index of the array. Returns false if the value can't be expressed as a decimal. decimal is a 128-bit floating point value with a 5 bit base-10 exponent and a 96-bit base-10 mantissa. Decimal128 is a fixed point 128 bit value where up to 128 bits can be used for the mantissa, and both the number of bits and the exponent are determined by the array's type (which is out-of-band). This means that a Decimal128Type whose precision minus scale is greater than 28 might produce an overflow when stored as a .NET decimal. It may also cause rounding for precisions greater than 28. These will silently succeed. By contrast, SqlDecimal can store a decimal128 value with full fidelity.
public bool TryGetValue(int index, out decimal? value)