Gurux.DLMS.GXByteBuffer.SetInt16 C# (CSharp) Méthode

SetInt16() public méthode

Push the given Int16 into this buffer at the given position.
public SetInt16 ( int index, Int16 value ) : void
index int Zero based byte index where value is set.
value System.Int16 The value to be added.
Résultat void
        public void SetInt16(int index, Int16 value)
        {
            if (index + 2 >= Capacity)
            {
                Capacity = (index + ArrayCapacity);
            }
            Data[index] = (byte)((value >> 8) & 0xFF);
            Data[index + 1] = (byte)(value & 0xFF);
        }

Same methods

GXByteBuffer::SetInt16 ( Int16 value ) : void