public ThalamusServerService(ClientsInterface bodyInterface, string clientAddress) { this.clients = bodyInterface; this.clientAddress = clientAddress; }
public Character(ClientsInterface body) : this("UnspecifiedCharacter" + Counter++, body) { }
public Character(string name, ClientsInterface body) { this.name = name; this.clients = body; this.LogToCSV = false; }
public ThalamusClientProxy(ClientsInterface body, string name, string address, int fastPort, int slowPort, string clientId, int numSubscribedEvents) { this.name = name; this.fastPort = fastPort; this.slowPort = slowPort; this.address = address; this.characterClients = body; this.clientId = clientId; this.numSubscribedEvents = numSubscribedEvents; acceptSocketPermission.Union(connectSocketPermission).Demand(); fastProxy = XmlRpcProxyGen.Create<IThalamusClientRpc>(); fastProxy.Url = string.Format("http://{0}:{1}", address, fastPort); fastProxy.KeepAlive = true; fastProxy.Timeout = Properties.Settings.Default.FastTimeout; slowProxy = XmlRpcProxyGen.Create<IThalamusClientRpc>(); slowProxy.Url = string.Format("http://{0}:{1}", address, slowPort); slowProxy.KeepAlive = true; slowProxy.Timeout = Properties.Settings.Default.SlowTimeout; //slowProxy = fastProxy; pingTimer.Interval = Properties.Settings.Default.PingInterval; pingTimer.Elapsed+=new ElapsedEventHandler(TimerPing); pingTimer.Start(); sentMessageDispatcherThread = new Thread (new ThreadStart (SentMessageDispatcher)); sentMessageDispatcherThread.Start (); receivedMessageDispatcherThread = new Thread(new ThreadStart(ReceivedMessageDispatcher)); receivedMessageDispatcherThread.Start(); }