public class DistributedSingletonService<T> extends Object implements SingletonService<T>, SingletonContext<T>, ServiceProviderRegistration.Listener, PrimaryProxyContext<T>
| Constructor and Description |
|---|
DistributedSingletonService(DistributedSingletonServiceContext<T> context) |
| Modifier and Type | Method and Description |
|---|---|
CommandDispatcher<SingletonContext<T>> |
getCommandDispatcher() |
Optional<T> |
getLocalValue() |
org.jboss.msc.service.ServiceName |
getServiceName() |
T |
getValue() |
boolean |
isPrimary() |
void |
providersChanged(Set<Node> nodes) |
void |
start() |
void |
start(org.jboss.msc.service.StartContext context) |
void |
stop() |
void |
stop(org.jboss.msc.service.StopContext context) |
public DistributedSingletonService(DistributedSingletonServiceContext<T> context)
public void start(org.jboss.msc.service.StartContext context)
throws org.jboss.msc.service.StartException
start in interface org.jboss.msc.service.Service<T>org.jboss.msc.service.StartExceptionpublic void stop(org.jboss.msc.service.StopContext context)
stop in interface org.jboss.msc.service.Service<T>public void providersChanged(Set<Node> nodes)
providersChanged in interface ServiceProviderRegistration.Listenerpublic void start()
start in interface SingletonContext<T>public void stop()
stop in interface SingletonContext<T>public Optional<T> getLocalValue()
getLocalValue in interface SingletonContext<T>public CommandDispatcher<SingletonContext<T>> getCommandDispatcher()
getCommandDispatcher in interface PrimaryProxyContext<T>public org.jboss.msc.service.ServiceName getServiceName()
getServiceName in interface PrimaryProxyContext<T>Copyright © 2018 JBoss by Red Hat. All rights reserved.