C# 클래스 GonzoNet.NetworkClient

파일 보기 프로젝트 열기: RHY3756547/FreeSO 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
m_Listener Listener
m_LoginArgs GonzoNet.LoginArgsContainer

공개 메소드들

메소드 설명
Connect ( GonzoNet.LoginArgsContainer LoginArgs ) : void

Connects to the login server.

Disconnect ( ) : void

Disconnects this NetworkClient instance and stops all sending and receiving of data.

GetPackets ( ) : Queue
NetworkClient ( Socket ClientSocket, Listener Server, EncryptionMode EMode ) : System

Initializes a client that listens for data.

NetworkClient ( string IP, int Port, EncryptionMode EMode, bool KeepAlive ) : System
ProcessPackets ( ) : void
Send ( byte Data ) : void
SendEncrypted ( byte PacketID, byte Data ) : void

Sends an encrypted packet to the server. Automatically appends the length of the packet after the ID, as the encrypted data can be smaller or longer than that of the unencrypted data.

보호된 메소드들

메소드 설명
OnSend ( IAsyncResult AR ) : void
ReceiveCallback ( IAsyncResult AR ) : void

비공개 메소드들

메소드 설명
BeginReceive ( ) : void
ConnectCallback ( IAsyncResult AR ) : void
FindPacketHandler ( byte ID ) : GonzoNet.PacketHandler
OnPacket ( GonzoNet.ProcessedPacket packet, GonzoNet.PacketHandler handler ) : void

메소드 상세

Connect() 공개 메소드

Connects to the login server.
public Connect ( GonzoNet.LoginArgsContainer LoginArgs ) : void
LoginArgs GonzoNet.LoginArgsContainer Arguments used for login. Can be null.
리턴 void

Disconnect() 공개 메소드

Disconnects this NetworkClient instance and stops all sending and receiving of data.
public Disconnect ( ) : void
리턴 void

GetPackets() 공개 메소드

public GetPackets ( ) : Queue
리턴 Queue

NetworkClient() 공개 메소드

Initializes a client that listens for data.
public NetworkClient ( Socket ClientSocket, Listener Server, EncryptionMode EMode ) : System
ClientSocket Socket The client's socket.
Server Listener The Listener instance calling this constructor.
EMode EncryptionMode
리턴 System

NetworkClient() 공개 메소드

public NetworkClient ( string IP, int Port, EncryptionMode EMode, bool KeepAlive ) : System
IP string
Port int
EMode EncryptionMode
KeepAlive bool
리턴 System

OnSend() 보호된 메소드

protected OnSend ( IAsyncResult AR ) : void
AR IAsyncResult
리턴 void

ProcessPackets() 공개 메소드

public ProcessPackets ( ) : void
리턴 void

ReceiveCallback() 보호된 메소드

protected ReceiveCallback ( IAsyncResult AR ) : void
AR IAsyncResult
리턴 void

Send() 공개 메소드

public Send ( byte Data ) : void
Data byte
리턴 void

SendEncrypted() 공개 메소드

Sends an encrypted packet to the server. Automatically appends the length of the packet after the ID, as the encrypted data can be smaller or longer than that of the unencrypted data.
public SendEncrypted ( byte PacketID, byte Data ) : void
PacketID byte The ID of the packet (will remain unencrypted).
Data byte The data that will be encrypted.
리턴 void

프로퍼티 상세

m_Listener 보호되어 있는 프로퍼티

protected Listener,GonzoNet m_Listener
리턴 Listener

m_LoginArgs 보호되어 있는 프로퍼티

protected LoginArgsContainer,GonzoNet m_LoginArgs
리턴 GonzoNet.LoginArgsContainer