C# Class System.BitConverter

Show file Open project: gbarnett/shared-source-cli-2.0 Class Usage Examples

Public Properties

Property Type Description
IsLittleEndian bool

Public Methods

Method Description
DoubleToInt64Bits ( double value ) : long
GetBytes ( bool value ) : byte[]
GetBytes ( char value ) : byte[]
GetBytes ( double value ) : byte[]
GetBytes ( float value ) : byte[]
GetBytes ( int value ) : byte[]
GetBytes ( long value ) : byte[]
GetBytes ( short value ) : byte[]
Int64BitsToDouble ( long value ) : double
ToBoolean ( byte value, int startIndex ) : bool
ToChar ( byte value, int startIndex ) : char
ToDouble ( byte value, int startIndex ) : double
ToInt16 ( byte value, int startIndex ) : short
ToInt32 ( byte value, int startIndex ) : int
ToInt64 ( byte value, int startIndex ) : long
ToSingle ( byte value, int startIndex ) : float
ToString ( byte value ) : String
ToString ( byte value, int startIndex ) : String
ToString ( byte value, int startIndex, int length ) : String

Private Methods

Method Description
GetBytes ( uint value ) : byte[]
GetBytes ( ulong value ) : byte[]
GetBytes ( ushort value ) : byte[]
GetHexValue ( int i ) : char
ToUInt16 ( byte value, int startIndex ) : ushort
ToUInt32 ( byte value, int startIndex ) : uint
ToUInt64 ( byte value, int startIndex ) : ulong

Method Details

DoubleToInt64Bits() public static method

public static DoubleToInt64Bits ( double value ) : long
value double
return long

GetBytes() public static method

public static GetBytes ( bool value ) : byte[]
value bool
return byte[]

GetBytes() public static method

public static GetBytes ( char value ) : byte[]
value char
return byte[]

GetBytes() public static method

public static GetBytes ( double value ) : byte[]
value double
return byte[]

GetBytes() public static method

public static GetBytes ( float value ) : byte[]
value float
return byte[]

GetBytes() public static method

public static GetBytes ( int value ) : byte[]
value int
return byte[]

GetBytes() public static method

public static GetBytes ( long value ) : byte[]
value long
return byte[]

GetBytes() public static method

public static GetBytes ( short value ) : byte[]
value short
return byte[]

Int64BitsToDouble() public static method

public static Int64BitsToDouble ( long value ) : double
value long
return double

ToBoolean() public static method

public static ToBoolean ( byte value, int startIndex ) : bool
value byte
startIndex int
return bool

ToChar() public static method

public static ToChar ( byte value, int startIndex ) : char
value byte
startIndex int
return char

ToDouble() public static method

public static ToDouble ( byte value, int startIndex ) : double
value byte
startIndex int
return double

ToInt16() public static method

public static ToInt16 ( byte value, int startIndex ) : short
value byte
startIndex int
return short

ToInt32() public static method

public static ToInt32 ( byte value, int startIndex ) : int
value byte
startIndex int
return int

ToInt64() public static method

public static ToInt64 ( byte value, int startIndex ) : long
value byte
startIndex int
return long

ToSingle() public static method

public static ToSingle ( byte value, int startIndex ) : float
value byte
startIndex int
return float

ToString() public static method

public static ToString ( byte value ) : String
value byte
return String

ToString() public static method

public static ToString ( byte value, int startIndex ) : String
value byte
startIndex int
return String

ToString() public static method

public static ToString ( byte value, int startIndex, int length ) : String
value byte
startIndex int
length int
return String

Property Details

IsLittleEndian public static property

public static bool IsLittleEndian
return bool