C# Class libopenpvp.net.AMF3Encoder

显示文件 Open project: mikolan/libopenpvp.net Class Usage Examples

Public Methods

Method Description
AddHeaders ( byte data ) : byte[]

Adds headers to provided data.

encode ( object obj ) : byte[]

Encodes an object as AMF3

encodeConnect ( object>.Dictionary parameters ) : byte[]

Encodes the given parameters as a val packet

encodeInvoke ( int id, object data ) : byte[]

Encodes the given data as a val packet

randomUID ( ) : string

Private Methods

Method Description
encode ( List ret, object obj ) : void

Encodes an object as AMF3 to the give buffer

writeArray ( List ret, object objects ) : void

Encodes an array of objects as AMF3 to the given buffer

writeAssociativeArray ( List ret, object>.Dictionary val ) : void

Encodes an Associative Array as AMF3 to the given buffer

writeByteArray ( List ret, byte bytes ) : void
writeDateTime ( List ret, System.DateTime dateTime ) : void

Encodes a DateTime object as AMF3 to the given buffer

writeDouble ( List ret, double val ) : void

Encodes a double as AMF3 to the given buffer

writeInt ( List ret, int val ) : void

Encodes and integer as AMF3 to a given buffer

writeIntAMFO ( List ret, int val ) : void

Encodes an integer as AMFO to the given buffer

writeString ( List ret, string val ) : void

Writes a string as AMF3 to the given buffer

writeobject ( List ret, TypedObject val ) : void

Encodes an object as AMF3 to the given buffer

writestringAMFO ( List ret, string val ) : void

Encodes a string as AMFO to the given buffer

Method Details

AddHeaders() public method

Adds headers to provided data.
public AddHeaders ( byte data ) : byte[]
data byte The data to add headers to.
return byte[]

encode() public method

Encodes an object as AMF3
public encode ( object obj ) : byte[]
obj object The object to encode
return byte[]

encodeConnect() public method

Encodes the given parameters as a val packet
public encodeConnect ( object>.Dictionary parameters ) : byte[]
parameters object>.Dictionary The connection parameters.
return byte[]

encodeInvoke() public method

Encodes the given data as a val packet
public encodeInvoke ( int id, object data ) : byte[]
id int The invoke ID
data object The data to invoke
return byte[]

randomUID() public static method

public static randomUID ( ) : string
return string