C# Class mhe.Protocol

ファイルを表示 Open project: icedmaster/mhe Class Usage Examples

Public Methods

Method Description
Connect ( string host, int port ) : bool
EncodeIntFromString ( string s ) : byte[]
EncodeString ( string s ) : byte[]
IsGlobalCommand ( Command cmd ) : bool
ParseFloat ( ByteStream stream ) : float
ParseInt ( ByteStream stream ) : int
ParseProfilerData ( string data ) : string
ParseString ( ByteStream stream ) : string
SendCPUProfilerCommand ( OnAnswer onAnswer ) : void
SendCommand ( Command cmd, byte args, OnAnswer onAnswer ) : void
SendGPUProfilerCommand ( OnAnswer onAnswer ) : void
SendGetAllCommand ( OnAnswer onAnswer ) : void
SendGetStatsCommand ( OnAnswer onAnswer ) : void
SendSetVarCommand ( byte varData, OnAnswer onAnswer ) : void

Private Methods

Method Description
ConvertToBytes ( int n ) : byte[]
ConvertToInt ( byte data ) : int
ParseProfilerDataString ( string data ) : List
Receive ( System.Result &result, byte &data ) : bool
Send ( Command cmd, byte data ) : bool

Method Details

Connect() public method

public Connect ( string host, int port ) : bool
host string
port int
return bool

EncodeIntFromString() public static method

public static EncodeIntFromString ( string s ) : byte[]
s string
return byte[]

EncodeString() public static method

public static EncodeString ( string s ) : byte[]
s string
return byte[]

IsGlobalCommand() public method

public IsGlobalCommand ( Command cmd ) : bool
cmd Command
return bool

ParseFloat() public static method

public static ParseFloat ( ByteStream stream ) : float
stream ByteStream
return float

ParseInt() public static method

public static ParseInt ( ByteStream stream ) : int
stream ByteStream
return int

ParseProfilerData() public method

public ParseProfilerData ( string data ) : string
data string
return string

ParseString() public static method

public static ParseString ( ByteStream stream ) : string
stream ByteStream
return string

SendCPUProfilerCommand() public method

public SendCPUProfilerCommand ( OnAnswer onAnswer ) : void
onAnswer OnAnswer
return void

SendCommand() public method

public SendCommand ( Command cmd, byte args, OnAnswer onAnswer ) : void
cmd Command
args byte
onAnswer OnAnswer
return void

SendGPUProfilerCommand() public method

public SendGPUProfilerCommand ( OnAnswer onAnswer ) : void
onAnswer OnAnswer
return void

SendGetAllCommand() public method

public SendGetAllCommand ( OnAnswer onAnswer ) : void
onAnswer OnAnswer
return void

SendGetStatsCommand() public method

public SendGetStatsCommand ( OnAnswer onAnswer ) : void
onAnswer OnAnswer
return void

SendSetVarCommand() public method

public SendSetVarCommand ( byte varData, OnAnswer onAnswer ) : void
varData byte
onAnswer OnAnswer
return void