C# Class Tickster.Utils.HexTranslator

ファイルを表示 Open project: tickster/Tickster.Utilities

Public Methods

Method Description
ToBytes ( string hex ) : byte[]

Converts a sequence of hexadecimal pairs into a byte array, ie F0 will yield [ 255 ] and FF00 will yield [ 255, 0 ]. This is the inverse function of ToHex(byte[] buffer)

ToHex ( byte buffer ) : string

"Hexifies" a byte array

ToHex ( byte buffer, int offset, int length ) : string

"Hexifies" a byte array

ToHex ( int value ) : string

"Hexifies" an integer

Method Details

ToBytes() public static method

Converts a sequence of hexadecimal pairs into a byte array, ie F0 will yield [ 255 ] and FF00 will yield [ 255, 0 ]. This is the inverse function of ToHex(byte[] buffer)
public static ToBytes ( string hex ) : byte[]
hex string
return byte[]

ToHex() public static method

"Hexifies" a byte array
public static ToHex ( byte buffer ) : string
buffer byte
return string

ToHex() public static method

"Hexifies" a byte array
public static ToHex ( byte buffer, int offset, int length ) : string
buffer byte
offset int
length int
return string

ToHex() public static method

"Hexifies" an integer
public static ToHex ( int value ) : string
value int
return string