C# Class ArtemisComm.Packet

Inheritance: IDisposable
Afficher le fichier Open project: russjudge/ArtemisSBS-ProtocolSharp Class Usage Examples

Private Properties

Свойство Type Description
BuildPackage IPackage
FormatIt string
GetLength int
GetPackage IPackage
GetRawData System.IO.MemoryStream
SetOrigin void
SetRawData void

Méthodes publiques

Méthode Description
Dispose ( ) : void
OverrideSetOrigin ( OriginType origin ) : void

sets the origin. Origin is normally not accessible since it can be deduced from the Packet type. However, this allows setting the origin for reverse-engineering the protocol AND for future-compatibility: if a new packet is built into a later version of Artemis, this library might not need updated to continue to support it.

OverrideSetPacketType ( PacketType packetType ) : void
OverrideSetPacketType ( int packetType ) : void
Packet ( IPackage package ) : System
Packet ( Stream stream ) : System

Méthodes protégées

Méthode Description
Dispose ( bool isDisposing ) : void

Private Methods

Méthode Description
BuildPackage ( MemoryStream stream, int index, Type packageType ) : IPackage
FormatIt ( byte buffer ) : string
GetLength ( byte byteArray, int startIndex ) : int
GetPackage ( MemoryStream stream, int index, Type packageType ) : IPackage
GetRawData ( ) : MemoryStream
SetOrigin ( ) : void

Sets the origin. Origin is not set if the Packet type is not among the defined list--this is to assume that it is working with a newer version of Artemis than originally written for.

SetRawData ( ) : void

Method Details

Dispose() public méthode

public Dispose ( ) : void
Résultat void

Dispose() protected méthode

protected Dispose ( bool isDisposing ) : void
isDisposing bool
Résultat void

OverrideSetOrigin() public méthode

sets the origin. Origin is normally not accessible since it can be deduced from the Packet type. However, this allows setting the origin for reverse-engineering the protocol AND for future-compatibility: if a new packet is built into a later version of Artemis, this library might not need updated to continue to support it.
public OverrideSetOrigin ( OriginType origin ) : void
origin OriginType The origin.
Résultat void

OverrideSetPacketType() public méthode

public OverrideSetPacketType ( PacketType packetType ) : void
packetType PacketType
Résultat void

OverrideSetPacketType() public méthode

public OverrideSetPacketType ( int packetType ) : void
packetType int
Résultat void

Packet() public méthode

public Packet ( IPackage package ) : System
package IPackage
Résultat System

Packet() public méthode

public Packet ( Stream stream ) : System
stream Stream
Résultat System