C# 클래스 KLFServer.Server

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

공개 프로퍼티들

프로퍼티 타입 설명
bannedIPs HashSet
clientActivityCountLock object
clientMessageQueue ConcurrentQueue
clients ServerClient[]
commandThread Thread
connectionThread Thread
consoleWriteLock object
httpListener HttpListener
listenThread Thread
outgoingMessageThread Thread
quit bool
savedThrottleStates ServerClient.ThrottleState>.Dictionary
settings ServerSettings
stop bool
stopwatch Stopwatch
tcpListener TcpListener
threadException Exception
threadExceptionLock object
threadExceptionStackTrace String
udpClient UdpClient

공개 메소드들

메소드 설명
Server ( ServerSettings settings ) : System
buildMessageArray ( KLFCommon id, byte data ) : byte[]
clearState ( ) : void
clientActivityLevelChanged ( int index ) : void
clientIsReady ( int index ) : bool
clientIsValid ( int index ) : bool
debugConsoleWriteLine ( String message ) : void
disconnectClient ( int index, String message ) : void
handleClientTextMessage ( int client_index, String message_text ) : void
handleMessage ( int client_index, KLFCommon id, byte data ) : void
hostingLoop ( ) : void
messageFloodIncrement ( int index ) : void
passExceptionToMain ( Exception e ) : void
queueClientMessage ( int client_index, KLFCommon id, byte data ) : void
saveScreenshot ( Screenshot screenshot, String player ) : void
sendOutgoingMessages ( ) : void
stampedConsoleWriteLine ( String message ) : void

비공개 메소드들

메소드 설명
addClient ( TcpClient tcp_client ) : int
asyncHTTPCallback ( IAsyncResult result ) : void
asyncUDPReceive ( IAsyncResult result ) : void
banClient ( int index ) : void
banIP ( IPAddress address ) : void
clearBans ( ) : void
getClientIP ( int index ) : IPAddress
getClientIndexByName ( String name ) : int
handleCommands ( ) : void
handleConnections ( ) : void
listenForClients ( ) : void
loadBanList ( ) : void
printCommands ( ) : void
safeAbort ( Thread thread, bool join = false ) : void
saveBanList ( ) : void
sendConnectionEndMessageDirect ( TcpClient client, String message ) : void
sendCraftFile ( int client_index, String craft_name, byte data, byte type ) : void
sendHandshakeMessage ( int client_index ) : void
sendHandshakeRefusalMessageDirect ( TcpClient client, String message ) : void
sendMessageHeaderDirect ( TcpClient client, KLFCommon id, int msg_length ) : void
sendPluginUpdateToAll ( byte data, bool in_flight_only, int exclude_index = -1 ) : void
sendScreenshot ( int client_index, Screenshot screenshot ) : void
sendScreenshotToWatchers ( int client_index, Screenshot screenshot ) : void
sendServerMessage ( int client_index, String message ) : void
sendServerMessageToAll ( String message, int exclude_index = -1 ) : void
sendServerSettings ( int client_index ) : void
sendServerSettingsToAll ( ) : void
sendTextMessage ( int client_index, String message ) : void
sendTextMessageToAll ( String message, int exclude_index = -1 ) : void
serverSettingBytes ( ) : byte[]
unbanIP ( IPAddress address ) : void

메소드 상세

Server() 공개 메소드

public Server ( ServerSettings settings ) : System
settings ServerSettings
리턴 System

buildMessageArray() 공개 정적인 메소드

public static buildMessageArray ( KLFCommon id, byte data ) : byte[]
id KLFCommon
data byte
리턴 byte[]

clearState() 공개 메소드

public clearState ( ) : void
리턴 void

clientActivityLevelChanged() 공개 메소드

public clientActivityLevelChanged ( int index ) : void
index int
리턴 void

clientIsReady() 공개 메소드

public clientIsReady ( int index ) : bool
index int
리턴 bool

clientIsValid() 공개 메소드

public clientIsValid ( int index ) : bool
index int
리턴 bool

debugConsoleWriteLine() 공개 정적인 메소드

public static debugConsoleWriteLine ( String message ) : void
message String
리턴 void

disconnectClient() 공개 메소드

public disconnectClient ( int index, String message ) : void
index int
message String
리턴 void

handleClientTextMessage() 공개 메소드

public handleClientTextMessage ( int client_index, String message_text ) : void
client_index int
message_text String
리턴 void

handleMessage() 공개 메소드

public handleMessage ( int client_index, KLFCommon id, byte data ) : void
client_index int
id KLFCommon
data byte
리턴 void

hostingLoop() 공개 메소드

public hostingLoop ( ) : void
리턴 void

messageFloodIncrement() 공개 메소드

public messageFloodIncrement ( int index ) : void
index int
리턴 void

passExceptionToMain() 공개 메소드

public passExceptionToMain ( Exception e ) : void
e Exception
리턴 void

queueClientMessage() 공개 메소드

public queueClientMessage ( int client_index, KLFCommon id, byte data ) : void
client_index int
id KLFCommon
data byte
리턴 void

saveScreenshot() 공개 메소드

public saveScreenshot ( Screenshot screenshot, String player ) : void
screenshot Screenshot
player String
리턴 void

sendOutgoingMessages() 공개 메소드

public sendOutgoingMessages ( ) : void
리턴 void

stampedConsoleWriteLine() 공개 정적인 메소드

public static stampedConsoleWriteLine ( String message ) : void
message String
리턴 void

프로퍼티 상세

bannedIPs 공개적으로 프로퍼티

public HashSet bannedIPs
리턴 HashSet

clientActivityCountLock 공개적으로 프로퍼티

public object clientActivityCountLock
리턴 object

clientMessageQueue 공개적으로 프로퍼티

public ConcurrentQueue clientMessageQueue
리턴 ConcurrentQueue

clients 공개적으로 프로퍼티

public ServerClient[] clients
리턴 ServerClient[]

commandThread 공개적으로 프로퍼티

public Thread commandThread
리턴 Thread

connectionThread 공개적으로 프로퍼티

public Thread connectionThread
리턴 Thread

consoleWriteLock 공개적으로 정적으로 프로퍼티

public static object consoleWriteLock
리턴 object

httpListener 공개적으로 프로퍼티

public HttpListener httpListener
리턴 HttpListener

listenThread 공개적으로 프로퍼티

public Thread listenThread
리턴 Thread

outgoingMessageThread 공개적으로 프로퍼티

public Thread outgoingMessageThread
리턴 Thread

quit 공개적으로 프로퍼티

public bool quit
리턴 bool

savedThrottleStates 공개적으로 프로퍼티

public Dictionary savedThrottleStates
리턴 ServerClient.ThrottleState>.Dictionary

settings 공개적으로 프로퍼티

public ServerSettings settings
리턴 ServerSettings

stop 공개적으로 프로퍼티

public bool stop
리턴 bool

stopwatch 공개적으로 프로퍼티

public Stopwatch stopwatch
리턴 Stopwatch

tcpListener 공개적으로 프로퍼티

public TcpListener tcpListener
리턴 TcpListener

threadException 공개적으로 프로퍼티

public Exception threadException
리턴 Exception

threadExceptionLock 공개적으로 프로퍼티

public object threadExceptionLock
리턴 object

threadExceptionStackTrace 공개적으로 프로퍼티

public String threadExceptionStackTrace
리턴 String

udpClient 공개적으로 프로퍼티

public UdpClient udpClient
리턴 UdpClient