@Beta @ThreadSafe public class ClientActorContext extends Object implements org.opendaylight.yangtools.concepts.Identifiable<org.opendaylight.controller.cluster.access.concepts.ClientIdentifier>
AbstractClientActor.
Time-keeping in a client actor is based on monotonic time. The precision of this time can be expected to be the
same as System.nanoTime(), but it is not tied to that particular clock. Actor clock is exposed as
a Ticker, which can be obtained via ticker().| Modifier and Type | Method and Description |
|---|---|
void |
executeInActor(InternalCommand command)
Execute a command in the context of the client actor.
|
akka.actor.Cancellable |
executeInActor(InternalCommand command,
scala.concurrent.duration.FiniteDuration delay) |
org.opendaylight.controller.cluster.access.concepts.ClientIdentifier |
getIdentifier() |
akka.actor.ActorRef |
self() |
com.google.common.base.Ticker |
ticker()
Return the time ticker for this
ClientActorContext. |
@Nonnull public org.opendaylight.controller.cluster.access.concepts.ClientIdentifier getIdentifier()
getIdentifier in interface org.opendaylight.yangtools.concepts.Identifiable<org.opendaylight.controller.cluster.access.concepts.ClientIdentifier>@Nonnull public com.google.common.base.Ticker ticker()
ClientActorContext. This should be used for in all time-tracking
done within a client actor. Subclasses of ClientActorBehavior are encouraged to use
Stopwatch.public void executeInActor(@Nonnull InternalCommand command)
command - Block of code which needs to be executepublic akka.actor.Cancellable executeInActor(@Nonnull InternalCommand command, scala.concurrent.duration.FiniteDuration delay)
@Nonnull public final akka.actor.ActorRef self()
Copyright © 2016 OpenDaylight. All rights reserved.