C# Class Akka.Interfaced.SlimSocket.PacketSerializerBase

Inheritance: IPacketSerializer
显示文件 Open project: SaladLab/Akka.Interfaced.SlimSocket Class Usage Examples

Public Methods

Method Description
Deserialize ( Stream stream ) : object
EstimateLength ( object packet ) : int
PeekLength ( Stream stream ) : int
Serialize ( Stream stream, object packet ) : void
SetDeserializeWrapKey ( int wrapKey ) : void
SetSerializeWrapKey ( int wrapKey, bool pending = false ) : void

Protected Methods

Method Description
GetBuffers ( Stream stream, int pos, int length, ArraySegment &segment0, ArraySegment &segment1 ) : void
PacketSerializerBase ( Data data ) : System

Private Methods

Method Description
Decrypt ( byte target, int targetOffset, byte source, int sourceOffset, int length, DecryptContext &ctx ) : void
Encrypt ( byte target, int targetOffset, byte source, int sourceOffset, int length, EncryptContext &ctx ) : void

Method Details

Deserialize() public method

public Deserialize ( Stream stream ) : object
stream Stream
return object

EstimateLength() public method

public EstimateLength ( object packet ) : int
packet object
return int

GetBuffers() protected abstract method

protected abstract GetBuffers ( Stream stream, int pos, int length, ArraySegment &segment0, ArraySegment &segment1 ) : void
stream Stream
pos int
length int
segment0 ArraySegment
segment1 ArraySegment
return void

PacketSerializerBase() protected method

protected PacketSerializerBase ( Data data ) : System
data Data
return System

PeekLength() public method

public PeekLength ( Stream stream ) : int
stream Stream
return int

Serialize() public method

public Serialize ( Stream stream, object packet ) : void
stream Stream
packet object
return void

SetDeserializeWrapKey() public method

public SetDeserializeWrapKey ( int wrapKey ) : void
wrapKey int
return void

SetSerializeWrapKey() public method

public SetSerializeWrapKey ( int wrapKey, bool pending = false ) : void
wrapKey int
pending bool
return void