FreeHEP API
Version current

hep.aida.ref.remote
Class RemoteServer

java.lang.Object
  extended byhep.aida.ref.remote.RemoteServer
All Implemented Interfaces:
AidaTreeServer

public class RemoteServer
extends Object
implements AidaTreeServer

This is implementation of the AidaTreeServer. This class does not have any remote transport layer (RMI, CORBA, etc.), so special adapter classes, like RmiRemoteServer, are used to provide such functionality. Default is to support duplex mode.

Author:
serbo
Source Code:
RemoteServer.java

Field Summary
protected  boolean blocking
           
protected  Logger remoteLogger
           
 
Constructor Summary
RemoteServer(IDevTree tree)
          Creates a new instance of RemoteServer
RemoteServer(IDevTree tree, boolean duplex)
           
RemoteServer(IDevTree tree, boolean duplex, boolean appendAxisType)
           
 
Method Summary
 void close()
          Disconnect servants for all client, server and release all allocated resources.
 AidaTreeServant connectDuplex(AidaTreeClient client)
          connect/disconnect methods for TreeClient that does support "Duplex" Mode.
 AidaTreeServant connectNonDuplex(String clientID)
          connect/disconnect methods for TreeClient that does not support "Duplex" Mode.
 boolean disconnectDuplex(AidaTreeClient client)
           
 boolean disconnectNonDuplex(String clientID)
           
 boolean isBlocking()
           
 void setBlocking(boolean b)
           
 void setUseValidation(boolean state)
          If useValidation = true, client has to call "setValid" method after receiving update from the ManagedObject in order to reseive next update.
 boolean supportDuplexMode()
          Returns "true" if this TreeServer/TreeServant implementation support "Duplex Mode".
 String treeName()
          Return the name of the ITree it is connected to.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

blocking

protected boolean blocking

remoteLogger

protected Logger remoteLogger
Constructor Detail

RemoteServer

public RemoteServer(IDevTree tree)
Creates a new instance of RemoteServer


RemoteServer

public RemoteServer(IDevTree tree,
                    boolean duplex)

RemoteServer

public RemoteServer(IDevTree tree,
                    boolean duplex,
                    boolean appendAxisType)
Method Detail

setBlocking

public void setBlocking(boolean b)

isBlocking

public boolean isBlocking()

setUseValidation

public void setUseValidation(boolean state)
If useValidation = true, client has to call "setValid" method after receiving update from the ManagedObject in order to reseive next update. If useValidation = false, client receives all updates.


close

public void close()
Disconnect servants for all client, server and release all allocated resources. RemoteServer does not function after that


connectDuplex

public AidaTreeServant connectDuplex(AidaTreeClient client)
Description copied from interface: AidaTreeServer
connect/disconnect methods for TreeClient that does support "Duplex" Mode. Reference to instance of TreeClient serves also as a unique client ID.

Specified by:
connectDuplex in interface AidaTreeServer

connectNonDuplex

public AidaTreeServant connectNonDuplex(String clientID)
Description copied from interface: AidaTreeServer
connect/disconnect methods for TreeClient that does not support "Duplex" Mode. TreeClient has to provide a unique "clientID" to TreeServer. If "clientID" is not unique, TreeServer changes it, so TreeClient must check "newClientID", returned by TreeServer.

Specified by:
connectNonDuplex in interface AidaTreeServer

disconnectDuplex

public boolean disconnectDuplex(AidaTreeClient client)
Specified by:
disconnectDuplex in interface AidaTreeServer

disconnectNonDuplex

public boolean disconnectNonDuplex(String clientID)
Specified by:
disconnectNonDuplex in interface AidaTreeServer

supportDuplexMode

public boolean supportDuplexMode()
Description copied from interface: AidaTreeServer
Returns "true" if this TreeServer/TreeServant implementation support "Duplex Mode".

Specified by:
supportDuplexMode in interface AidaTreeServer

treeName

public String treeName()
Description copied from interface: AidaTreeServer
Return the name of the ITree it is connected to.

Specified by:
treeName in interface AidaTreeServer

FreeHEP API
Version current

Copyright © 2000-2004 FreeHEP, All Rights Reserved.