ABLE 2.0.0 07/02/2003 10:25:01

com.ibm.able
Interface AbleRemoteAgent

All Superinterfaces:
AbleBeanRemoteContainer, AbleEventListenerRemoteManager, AbleEventQueueRemoteManager, AbleRemoteBean, AbleRemoteEventListener, AbleUserDefinedFunctionRemoteManager, java.rmi.Remote, java.io.Serializable
All Known Subinterfaces:
AblePlatformAgent, AutotuneAgentIf, JasKnnDistributedAgentIF, JasNaiveBayesDistributedAgentIF
All Known Implementing Classes:
AbleRemoteDefaultAgent

public interface AbleRemoteAgent
extends AbleRemoteBean, AbleBeanRemoteContainer, AbleUserDefinedFunctionRemoteManager

The AbleRemoteAgent interface defines a remote AbleAgent, an AbleRemoteBean container which can contain other AbleBeans. The AbleRemoteAgent interface provides methods to manipulate contained beans, maintain a registry of user-definable methods on those beans, and determine the agent's address, host name, and input structure, and maintain a registry of user-definable methods on those beans it contains. Implementors must provide:

  1. Methods to add and remove event connections, which are serializable event listeners.
  2. Methods to set and get a flag indicating there is a contained bean that is the currently active datasource, and a method to get that datasource to allow other agents to learn its inputBuffer structure.
  3. Methods to get the agent's name, host, and address.


Method Summary
 void addEventConnection(AbleEventConnection theConnection)
          Adds an event connection.
 java.lang.String getAgentAddr()
          Returns the address of this agent.
 java.lang.String getAgentHost()
          Returns the name of the host on which this agent is running.
 java.lang.String getAgentName()
          Returns the current formal agent name of this agent.
 AbleDataSource getDataSource()
          Returns the current active DataSource from the contained beans, null if none.
 boolean isActiveDataSource()
          Indicates if this agent has an active data source.
 void removeEventConnection(AbleEventConnection theConnection)
          Removes an event connection.
 void setActiveDataSource(boolean theState)
          Sets the flag indicating if this agent contains an active data source.
 
Methods inherited from interface com.ibm.able.AbleRemoteBean
getName, getState, init, init, process, process, quitAll, reset, resumeAll, suspendAll
 
Methods inherited from interface com.ibm.able.AbleRemoteEventListener
handleAbleEvent
 
Methods inherited from interface com.ibm.able.AbleEventListenerRemoteManager
addAbleEventListener, notifyAbleEventListeners, removeAbleEventListener
 
Methods inherited from interface com.ibm.able.AbleEventQueueRemoteManager
flushAbleEventQueue, getAbleEventProcessingEnabled, getAbleEventQueueSize, getSleepTime, isTimerEventProcessingEnabled, quitEnabledEventProcessing, restartEnabledEventProcessing, resumeEnabledEventProcessing, setAbleEventProcessingEnabled, setSleepTime, setTimerEventProcessingEnabled, startEnabledEventProcessing, suspendEnabledEventProcessing
 
Methods inherited from interface com.ibm.able.AbleBeanRemoteContainer
addBean, containsBean, containsBean, getBean, getBeans, removeAllBeans, removeBean, removeBean
 
Methods inherited from interface com.ibm.able.AbleUserDefinedFunctionRemoteManager
addUserDefinedFunction, containsUserDefinedFunction, getUserDefinedFunction, getUserDefinedFunctions, invokeUserDefinedFunction, removeUserDefinedFunction, setUserDefinedFunctions
 

Method Detail

getAgentAddr

public java.lang.String getAgentAddr()
                              throws java.rmi.RemoteException
Returns the address of this agent.
Returns:
The address of this agent or the empty string if the agent is not initialized. The value is never expected to be null.
Throws:
java.rmi.RemoteException - If an error occurs.

getAgentHost

public java.lang.String getAgentHost()
                              throws java.rmi.RemoteException
Returns the name of the host on which this agent is running.
Returns:
The name of the host on which this agent is running or the empty string if the agent is not initialized. The value is never expected to be null.
Throws:
java.rmi.RemoteException - If an error occurs.

getAgentName

public java.lang.String getAgentName()
                              throws java.rmi.RemoteException
Returns the current formal agent name of this agent.
Returns:
The "agent name" of this agent.

The agent name may be in the form of a simple name (the same as returned by AbleRemoteBean.getName() ), an RMI registry name, or a JAS-type name, depending on the environment in which the agent is created and used. The value is never expected to be null and will be the empty string if the agent is not initialized.

Throws:
java.rmi.RemoteException - If an error occurs.

setActiveDataSource

public void setActiveDataSource(boolean theState)
                         throws java.rmi.RemoteException
Sets the flag indicating if this agent contains an active data source.
Parameters:
theState - The state is true if the agent contains an active data source, and false otherwise.
Throws:
java.rmi.RemoteException - If an error occurs.

isActiveDataSource

public boolean isActiveDataSource()
                           throws java.rmi.RemoteException
Indicates if this agent has an active data source.
Returns:
true if agent contains an active data source; false otherwise.
Throws:
java.rmi.RemoteException - If an error occurs.

getDataSource

public AbleDataSource getDataSource()
                             throws java.rmi.RemoteException
Returns the current active DataSource from the contained beans, null if none.
Returns:
The current active data source
Throws:
java.rmi.RemoteException - If an error occurs.

addEventConnection

public void addEventConnection(AbleEventConnection theConnection)
                        throws java.rmi.RemoteException
Adds an event connection.
Parameters:
theConnection - The connection to add.
Throws:
java.rmi.RemoteException - If an error occurs.

removeEventConnection

public void removeEventConnection(AbleEventConnection theConnection)
                           throws java.rmi.RemoteException
Removes an event connection.
Parameters:
theConnection - The connection to remove.
Throws:
java.rmi.RemoteException - If an error occurs. The implementor may choose to throw an exception if the connection does not exist.

ABLE 2.0.0 07/02/2003 10:25:01

(C) Copyright IBM Corporation 1999, 2003