| Modifier and type | Property and description |
|---|---|
| ConcurrentCollection<T> | registeredBehaviors
Replies the registered behaviors. |
| Modifier and type | Action and description |
|---|---|
| abstract EventListener | asEventListener
Replies the interface to dispatch an event to agent's Behaviors. |
| abstract ConcurrentCollection<T> | getRegisteredBehaviors
Replies the registered behaviors. |
| abstract boolean | hasRegisteredBehavior
Replies true if at least a behavior is registered. |
| abstract Behavior | registerBehavior(Behavior,[Function1<Param,Result>],Object*)
Register a Behavior for the owner agent. |
| abstract Behavior | unregisterBehavior(Behavior)
Unregisters a behavior for the owner agent. |
| abstract void | wake(Behavior,Event)
Wake a specific agent's behavior reacting to the Event evt. |
| abstract void | wake(Event,[Scope<T>])
Wake the agent's behaviors reacting to the Event evt. |
| abstract void | wake(Iterable<T>,Event)
Wake a set of specific agent's behaviors reacting to the Event evt. |
val registeredBehaviors : ConcurrentCollection<T>
This property is an alias for the action: getRegisteredBehaviors
def asEventListener : EventListener
def getRegisteredBehaviors : ConcurrentCollection<T>
def hasRegisteredBehavior : boolean
true if at least a behavior is registered.
A registered behavior is not necessary running. It may wait for events.
def registerBehavior(Behavior,[Function1<Param,Result>],Object*) : Behavior
true for a specific event as argument, the event is fired in the behavior context. If the filter function replies false, the event is not fired in the behavior context.
This function does nothing if one of the following conditions evaluates to true:
def unregisterBehavior(Behavior) : Behavior
def wake(Behavior,Event)
def wake(Event,[Scope<T>])
def wake(Iterable<T>,Event)