C# Class SocketLibrary.Packets.PacketProcessor

Afficher le fichier Open project: Wotuu/RTS_XNA_v2 Class Usage Examples

Méthodes publiques

Méthode Description
PacketProcessor ( ) : System
QueuePacket ( byte fullData, SocketClient receiver ) : void

SentPacket ( Packet p, SocketClient client ) : void

Called when the packet is sent.

StartProcessing ( ) : void

Spawns a thread to start processing packets

StopProcessing ( ) : void

Kills the thread, making it stop processing packets!

Private Methods

Méthode Description
BytesToString ( byte data ) : String

Converts a byte array to a string.

ConfirmPacket ( int packetID ) : void

Confirms a packet ID.

ConstructPacket ( byte fullData ) : SocketLibrary.Packets.Packet[]

Constructs a packet from a full byte array.

ProcessQueue ( ) : void
StringToBytes ( String str ) : byte[]

Converts a string to bytes.

Method Details

PacketProcessor() public méthode

public PacketProcessor ( ) : System
Résultat System

QueuePacket() public méthode

public QueuePacket ( byte fullData, SocketClient receiver ) : void
fullData byte
receiver SocketClient
Résultat void

SentPacket() public méthode

Called when the packet is sent.
public SentPacket ( Packet p, SocketClient client ) : void
p Packet The packet that was sent.
client SocketClient
Résultat void

StartProcessing() public méthode

Spawns a thread to start processing packets
public StartProcessing ( ) : void
Résultat void

StopProcessing() public méthode

Kills the thread, making it stop processing packets!
public StopProcessing ( ) : void
Résultat void