C# Класс Pdelvo.Minecraft.Proxy.Library.ProxyServer

The base implementation of a proxy server.
Наследование: IProxyServer
Показать файл Открыть проект Примеры использования класса

Private Properties

Свойство Тип Описание
PromoteConnection void
ReadConfig void
ReceiveClientsAsync void
RemoveConnection void

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

Метод Описание
CheckUserAccountAsync ( ProxyConnection proxyConnection, string hash ) : Task

checks if a user account is valid using plugins and the minecraft.net services

Dispose ( ) : void

Close all active connections and free resources synchronously

GetServerEndPoint ( IProxyConnection proxyConnection ) : RemoteServerInfo

Get a new server end point for a given proxy connection to.

GetServerVersion ( IProxyConnection proxyConnection, RemoteServerInfo serverEndPoint ) : void

Get the minecraft protocol server of a given minecraft server.

OnlineModeEnabled ( IProxyConnection proxyConnection ) : bool

Returns true if the online mode is enabled for a specific user or not.

ProxyServer ( ) : System

Creates a new instance of the ProxyServer class.

Start ( ) : void

Start listening for new users.

StopAsync ( ) : System.Threading.Tasks.Task

Close all active connections and free resources asynchronously

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

Метод Описание
PromoteConnection ( ProxyConnection proxyConnection ) : void
ReadConfig ( ) : void
ReceiveClientsAsync ( ) : void
RemoveConnection ( ProxyConnection proxyConnection ) : void

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

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

checks if a user account is valid using plugins and the minecraft.net services
public CheckUserAccountAsync ( ProxyConnection proxyConnection, string hash ) : Task
proxyConnection Pdelvo.Minecraft.Proxy.Library.Connection.ProxyConnection The proxy server which should be checked.
hash string The 'serverId' hash
Результат Task

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

Close all active connections and free resources synchronously
public Dispose ( ) : void
Результат void

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

Get a new server end point for a given proxy connection to.
public GetServerEndPoint ( IProxyConnection proxyConnection ) : RemoteServerInfo
proxyConnection IProxyConnection The proxy connection which need a new server connection.
Результат RemoteServerInfo

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

Get the minecraft protocol server of a given minecraft server.
public GetServerVersion ( IProxyConnection proxyConnection, RemoteServerInfo serverEndPoint ) : void
proxyConnection IProxyConnection The connection this server relates to.
serverEndPoint RemoteServerInfo The current version of the Remote server info.
Результат void

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

Returns true if the online mode is enabled for a specific user or not.
public OnlineModeEnabled ( IProxyConnection proxyConnection ) : bool
proxyConnection IProxyConnection The proxy connection which should be checked
Результат bool

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

Creates a new instance of the ProxyServer class.
public ProxyServer ( ) : System
Результат System

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

Start listening for new users.
public Start ( ) : void
Результат void

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

Close all active connections and free resources asynchronously
public StopAsync ( ) : System.Threading.Tasks.Task
Результат System.Threading.Tasks.Task