Click or drag to resize

BigEndianCopyBytesT(T, Byte*) Method

Copies the specified primitive type value as an array of bytes in the target endian-order to the destination array.

Namespace: GSF
Assembly: GSF.Core (in GSF.Core.dll) Version: 2.4.220-beta+a56b2444ff27b37e053039e60f062b99378309bd
Syntax
public static int CopyBytes<T>(
	T value,
	byte* destination
)
where T : struct, new(), IConvertible
View Source

Parameters

value  T
The Boolean value to convert and copy.
destination  Byte*
The destination buffer.

Type Parameters

T
Native value type to get bytes for.

Return Value

Int32
Length of bytes copied into array based on size of T.
Exceptions
ExceptionCondition
ArgumentExceptionvalue type is not primitive.
InvalidOperationExceptionCannot get bytes for value type.
See Also