|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectfr.dyade.aaa.agent.Channel
public class Channel
Class Channel
realizes the interface for sending messages.
It defines function member SendTo to send a notification to an identified
agent.
Notifications are then routed to a message queue where they are stored in chronological order. The Channel object is responsible for localizing the target agent.
Field Summary | |
---|---|
protected org.objectweb.util.monolog.api.Logger |
logmon
|
Constructor Summary | |
---|---|
protected |
Channel()
Constructs a new Channel object (can only be used by
subclasses). |
Method Summary | |
---|---|
static void |
sendTo(AgentId to,
Notification not)
Sends a notification to an agent. |
java.lang.String |
toString()
Returns a string representation of this Channel object. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected org.objectweb.util.monolog.api.Logger logmon
Constructor Detail |
---|
protected Channel()
Channel
object (can only be used by
subclasses).
Method Detail |
---|
public static final void sendTo(AgentId to, Notification not)
sendTo
function defined in class Agent
from an agent
code executed during a reaction.
The destination agent receives the notification with a declared null
source agent id, which may be recognized using the isNullId
function of class AgentId
.
This is not true when this call is performed during an standard agent
reaction. In that case the current reacting agent, known by the engine,
is provided as source agent.
The notification is immediately validated, that is made persistent, if it is not sent from an agent reaction. Be careful, does not use this method in the engine thread, sometime engine.agent is null and it throws a NullPointerException.
to
- destination agent.not
- notification.
java.io.IOException
- error when accessing the local persistent storagepublic final java.lang.String toString()
Channel
object.
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |