public class GuardedContextImpl extends Object implements GuardedContext
Modifier and Type | Method and Description |
---|---|
void |
close() |
com.google.common.util.concurrent.ListenableFuture<Void> |
closeServiceInstance() |
DeviceInfo |
getDeviceInfo()
Get device info.
|
org.opendaylight.mdsal.singleton.common.api.ServiceGroupIdentifier |
getIdentifier() |
void |
instantiateServiceInstance() |
<T> T |
map(Function<OFPContext,T> transformer)
Maps delegate inside guarded context to T.
|
void |
registerMastershipWatcher(ContextChainMastershipWatcher contextChainMastershipWatcher)
Registers mastership change listener to context.
|
com.google.common.util.concurrent.Service.State |
state()
Returns the lifecycle state of the service.
|
String |
toString() |
public com.google.common.util.concurrent.Service.State state()
GuardedContext
state
in interface GuardedContext
public <T> T map(Function<OFPContext,T> transformer)
GuardedContext
map
in interface GuardedContext
T
- the type parametertransformer
- the transformerpublic void instantiateServiceInstance()
instantiateServiceInstance
in interface org.opendaylight.mdsal.singleton.common.api.ClusterSingletonService
public com.google.common.util.concurrent.ListenableFuture<Void> closeServiceInstance()
closeServiceInstance
in interface org.opendaylight.mdsal.singleton.common.api.ClusterSingletonService
@Nonnull public org.opendaylight.mdsal.singleton.common.api.ServiceGroupIdentifier getIdentifier()
getIdentifier
in interface org.opendaylight.yangtools.concepts.Identifiable<org.opendaylight.mdsal.singleton.common.api.ServiceGroupIdentifier>
public DeviceInfo getDeviceInfo()
OFPContext
getDeviceInfo
in interface OFPContext
public void registerMastershipWatcher(@Nonnull ContextChainMastershipWatcher contextChainMastershipWatcher)
OFPContext
registerMastershipWatcher
in interface OFPContext
contextChainMastershipWatcher
- mastership change listenerpublic void close()
close
in interface AutoCloseable
close
in interface OFPContext
Copyright © 2018 OpenDaylight. All rights reserved.