From aea7b88c97d8cd57fdf7ba735eddc457c49aa09d Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 09:58:43 +0000 Subject: Utilisateur : Fcolin Date : 10/02/06 Heure : 16:37 Archivé dans $/CSharp/Ivy/Ivy Commentaire: (vss 41) --- CSharp/Ivy/IvyPPC/IvyClient.cs | 37 ++++++++++++++++++++++--------------- 1 file changed, 22 insertions(+), 15 deletions(-) (limited to 'CSharp/Ivy/IvyPPC/IvyClient.cs') diff --git a/CSharp/Ivy/IvyPPC/IvyClient.cs b/CSharp/Ivy/IvyPPC/IvyClient.cs index 547875c..649ea80 100644 --- a/CSharp/Ivy/IvyPPC/IvyClient.cs +++ b/CSharp/Ivy/IvyPPC/IvyClient.cs @@ -94,7 +94,7 @@ namespace IvyBus // protected variables internal String appName; - internal IvyTCPStream stream; + internal IvyProtocol stream; internal IvyClient(Ivy bus, Socket socket, string appname) { @@ -348,9 +348,16 @@ namespace IvyBus bus.removeClient(this); } - - - override internal void TokenDie(ushort id, string arg) + void IvyProtocol.Close() + { + // never call in this side + } + bool IvyProtocol.receiveMsg() + { + // nerver call in this side + return false; + } + void IvyProtocol.TokenDie(ushort id, string arg) { traceDebug("received die Message from " + appName + "Raison: "+ arg); // invokes the die applicationListeners @@ -363,7 +370,7 @@ namespace IvyBus if (killapp == Ivy.ApplicationExit.FORCE_EXIT) System.Windows.Forms.Application.Exit(); } - override internal void TokenBye(ushort err, string arg) + void IvyProtocol.TokenBye(ushort err, string arg) { // the peer quits traceDebug("received bye Message from " + appName + "Raison: "+ arg); @@ -374,7 +381,7 @@ namespace IvyBus close(false); // will fire diconnected } - override internal void TokenAddBinding(Ivy.ApplicationBinding bind) + void IvyProtocol.TokenAddBinding(Ivy.ApplicationBinding bind) { try { @@ -395,7 +402,7 @@ namespace IvyBus } } - override internal void TokenDelBinding(ushort id) + void IvyProtocol.TokenDelBinding(ushort id) { lock( bindings ) { @@ -411,16 +418,16 @@ namespace IvyBus } } } - override internal void TokenMsg(ushort id, string[] arg) + void IvyProtocol.TokenMsg(ushort id, string[] arg) { bus.FireCallback(this, id, arg); } - override internal void TokenError(ushort id, string arg) + void IvyProtocol.TokenError(ushort id, string arg) { bus.FireError(this, id, arg); traceDebug("Error msg " + id + " " + arg); } - override internal void TokenApplicationId(ushort id, string arg) + void IvyProtocol.TokenApplicationId(ushort id, string arg) { clientId = arg; if ( clientPriority != id ) @@ -429,7 +436,7 @@ namespace IvyBus bus.SortClients(); } } - override internal void TokenEndRegexp() + void IvyProtocol.TokenEndRegexp() { bus.FireClientConnected(this); /* @@ -439,7 +446,7 @@ namespace IvyBus if (bus.ReadyMessage != null) sendMsg(bus.ReadyMessage); } - override internal void TokenStartRegexp(ushort id, string arg) + void IvyProtocol.TokenStartRegexp(ushort id, string arg) { appName = arg; appPort = id; @@ -450,18 +457,18 @@ namespace IvyBus } } - override internal void TokenDirectMsg(ushort id, string arg) + void IvyProtocol.TokenDirectMsg(ushort id, string arg) { bus.FireDirectMessage(this, id, arg ); } - override internal void TokenPing(string arg) + void IvyProtocol.TokenPing(string arg) { // I receive a ping. I can answer a pong. traceDebug("Ping msg from " + appName + " : " + arg ); stream.TokenPong(arg); } - override internal void TokenPong(string arg) + void IvyProtocol.TokenPong(string arg) { traceDebug("Ping msg from " + appName + " : " + arg); } -- cgit v1.1