Register a client trigger, returning a "registryTrigger"
for the client to use.
IMPORTANT:
The org.cougaar.util.SyncTriggerModelImpl
should be used to wrap the returned "registryTrigger".
The SyncTriggerModelImpl is internally synchronized to
only run one "clientTrigger.trigger()" at a time, and to
buffer up triggers for more efficient scheduler use.
Additionally the TriggerModel includes "suspend()" and
"resume()" support that is required to correctly
implement client state transitions.
Without that wrapping it is possible for the "clientTrigger"
to be invoked in parallel under some TriggerRegistry
implementations. Minimally this would require the
"clientTrigger.trigger()" to be synchronized.
a "registryTrigger" that the caller can use to tellthe trigger-registry that it wants to be "clientTrigger.trigger()"ed. |