System::BitConverter::GetBytes method

BitConverter::GetBytes(bool) method

Converts the specified boolean value into an array of bytes.

static System::ArrayPtr<uint8_t> System::BitConverter::GetBytes(bool value)
ParameterTypeDescription
valueboolA boolean value to convert

ReturnValue

1-byte array representing specified value

See Also

BitConverter::GetBytes(char_t) method

Converts the specified char_t value into an array of bytes.

static System::ArrayPtr<uint8_t> System::BitConverter::GetBytes(char_t value)
ParameterTypeDescription
valuechar_tA char_t value to convert

ReturnValue

2-byte array representing specified value

See Also

BitConverter::GetBytes(double) method

Converts the specified double-precision floating-point value into an array of bytes.

static System::ArrayPtr<uint8_t> System::BitConverter::GetBytes(double value)
ParameterTypeDescription
valuedoubleA floating-point value to convert

ReturnValue

8-byte array representing specified value

See Also

BitConverter::GetBytes(float) method

Converts the specified single-precision floating-point value into an array of bytes.

static System::ArrayPtr<uint8_t> System::BitConverter::GetBytes(float value)
ParameterTypeDescription
valuefloatA floating-point value to convert

ReturnValue

4-byte array representing specified value

See Also

BitConverter::GetBytes(int) method

Converts the specified 32-bit integer value into an array of bytes.

static System::ArrayPtr<uint8_t> System::BitConverter::GetBytes(int value)
ParameterTypeDescription
valueintA 32-bit integer value to convert

ReturnValue

4-byte array representing specified value

See Also

BitConverter::GetBytes(int16_t) method

Converts the specified 16-bit integer value into an array of bytes.

static System::ArrayPtr<uint8_t> System::BitConverter::GetBytes(int16_t value)
ParameterTypeDescription
valueint16_tA 16-bit integer value to convert

ReturnValue

2-byte array representing specified value

See Also

BitConverter::GetBytes(int64_t) method

Converts the specified 64-bit integer value into an array of bytes.

static System::ArrayPtr<uint8_t> System::BitConverter::GetBytes(int64_t value)
ParameterTypeDescription
valueint64_tA 64-bit integer value to convert

ReturnValue

8-byte array representing specified value

See Also

BitConverter::GetBytes(uint16_t) method

Converts the specified unsigned 16-bit integer value into an array of bytes.

static System::ArrayPtr<uint8_t> System::BitConverter::GetBytes(uint16_t value)
ParameterTypeDescription
valueuint16_tAn unsigned 16-bit integer value to convert

ReturnValue

2-byte array representing specified value

See Also

BitConverter::GetBytes(uint32_t) method

Converts the specified unsigned 32-bit integer value into an array of bytes.

static System::ArrayPtr<uint8_t> System::BitConverter::GetBytes(uint32_t value)
ParameterTypeDescription
valueuint32_tAn unsigned 32-bit integer value to convert

ReturnValue

4-byte array representing specified value

See Also

BitConverter::GetBytes(uint64_t) method

Converts the specified unsigned 64-bit integer value into an array of bytes.

static System::ArrayPtr<uint8_t> System::BitConverter::GetBytes(uint64_t value)
ParameterTypeDescription
valueuint64_tAn unsigned 64-bit integer value to convert

ReturnValue

8-byte array representing specified value

See Also