Skip to main content

ClientHandler

A class in Root.Township, the global namespace.

Server: one connected remote console client. Made by ServerRemoteConsole from the socket and the client's JWT, and wraps a command handler and log sender.

Constructors​

MemberWhat it is
ClientHandler(Socket clientSocket, JwtSecurityToken token)Creates a ClientHandler from clientSocket and token.

Properties​

MemberWhat it is
IPEndPoint ClientEndpoint { get; }The client's IP endpoint.
ClientCommandHandler CommandHandler { get; }Handles commands from this client.
ClientLogSender LogSender { get; }Sends subscribed log output to this client.
UserInfoWithPermissions UserInfo { get; }User and permissions read from the client's token.

Events​

MemberWhat it is
event Action<ClientHandler> DisconnectedRaised when the client is terminated.

Methods​

MemberWhat it is
void Terminate()Closes the command handler and log sender and raises Disconnected. Runs when the command handler disconnects.

Used in​

Members of other types that take, return or hold a ClientHandler: