C# Класс POLUtils.AuxSvc.AuxSvcConnection

Provides a stream that implements the AuxSvc protocol.
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
AuxSvcConnection ( string server_ip, int server_port ) : System.IO

Creates an AuxSvc object against the specified socket to designated Server IP and Server Port. It then initializes and connects the AuxSocket and uses the AuxSocket to initialize the AuxStream for our Read/Write work.

Close ( ) : void

Closes all AuxSvcConnection related Streams. Can be used to manually kill an AuxSvcConnection if an error is encountered before using Write(). Will result in the AuxSvc Script in POL to exit the While(connection) Loop and terminate.

Read ( ) : string

Returns the current contents of the AuxStream in string format.

Write ( string input ) : bool

Attempts to send a string using the AuxWriter Stream. Returns a bool for success.

Приватные методы

Метод Описание
AuxSvcConnection ( ) : System.IO

The default constructor is marked as private to ensure the parameterized constructor is called.

Описание методов

AuxSvcConnection() публичный Метод

Creates an AuxSvc object against the specified socket to designated Server IP and Server Port. It then initializes and connects the AuxSocket and uses the AuxSocket to initialize the AuxStream for our Read/Write work.
public AuxSvcConnection ( string server_ip, int server_port ) : System.IO
server_ip string /// The ip that the AuxSvcStream will try to connect to. ///
server_port int /// The port that the AuxSvcStream will try to connect to. ///
Результат System.IO

Close() публичный Метод

Closes all AuxSvcConnection related Streams. Can be used to manually kill an AuxSvcConnection if an error is encountered before using Write(). Will result in the AuxSvc Script in POL to exit the While(connection) Loop and terminate.
public Close ( ) : void
Результат void

Read() публичный Метод

Returns the current contents of the AuxStream in string format.
public Read ( ) : string
Результат string

Write() публичный Метод

Attempts to send a string using the AuxWriter Stream. Returns a bool for success.
public Write ( string input ) : bool
input string /// The POL Style Packed string to send to the POL Server. ///
Результат bool