Skip to content

ByteSpanExtensions.SetInt16 Method

Overloads

Name Description
SetInt16(Span<Byte>, Int16) Writes a little-endian Int16 to a span of bytes.
SetInt16(Span<Byte>, Int16, Endian) Writes a Int16 to a span of bytes using the specified endianness.

SetInt16(Span<Byte>, Int16)

Writes a little-endian Int16 to a span of bytes.

public static void SetInt16(this Span<Byte> bytes, Int16 value);

View source

Parameters

Name Type Description
bytes Span<Byte>
value Int16 The value to write.

SetInt16(Span<Byte>, Int16, Endian)

Writes a Int16 to a span of bytes using the specified endianness.

public static void SetInt16(this Span<Byte> bytes, Int16 value, Endian endian);

View source

Parameters

Name Type Description
bytes Span<Byte>
value Int16 The value to write.
endian Endian The endianness to use.