Class DeviceFormatters.ScaledInt32
A decimal stored as a signed 32-bit value scaled by 10^decimals.
public abstract class DeviceFormatters.ScaledInt32 : IDeviceBinaryFieldFormatter<decimal>
- Inheritance
-
DeviceFormatters.ScaledInt32
- Implements
- Inherited Members
- Extension Methods
Constructors
ScaledInt32(int)
A decimal stored as a signed 32-bit value scaled by 10^decimals.
protected ScaledInt32(int decimals)
Parameters
decimalsint
Properties
Size
Gets how many bytes the field takes.
public int Size { get; }
Property Value
Methods
Read(ReadOnlySpan<byte>, bool)
Reads the value from exactly Size bytes.
public decimal Read(ReadOnlySpan<byte> source, bool bigEndian)
Parameters
sourceReadOnlySpan<byte>bigEndianbool
Returns
Write(decimal, Span<byte>, bool)
Writes the value into exactly Size bytes.
public void Write(decimal value, Span<byte> destination, bool bigEndian)