FunctionalService.@Deprecated public class FunctionalValueService<T,V> extends Object implements org.jboss.msc.service.Service<V>
Service whose value is created and destroyed by contextual functions.| Constructor and Description |
|---|
FunctionalValueService(Function<T,V> mapper,
org.wildfly.common.function.ExceptionFunction<org.jboss.msc.service.StartContext,T,org.jboss.msc.service.StartException> factory,
BiConsumer<org.jboss.msc.service.StopContext,T> destroyer)
Deprecated.
Constructs a new functional value service.
|
| Modifier and Type | Method and Description |
|---|---|
V |
getValue()
Deprecated.
|
void |
start(org.jboss.msc.service.StartContext context)
Deprecated.
|
void |
stop(org.jboss.msc.service.StopContext context)
Deprecated.
|
public FunctionalValueService(Function<T,V> mapper, org.wildfly.common.function.ExceptionFunction<org.jboss.msc.service.StartContext,T,org.jboss.msc.service.StartException> factory, BiConsumer<org.jboss.msc.service.StopContext,T> destroyer)
mapper - a function that maps the result of the factory function to the service valuefactory - a function that creates a valuedestroyer - a consumer that destroys the value created by the factory functionpublic V getValue()
getValue in interface org.jboss.msc.value.Value<V>public void start(org.jboss.msc.service.StartContext context)
throws org.jboss.msc.service.StartException
start in interface org.jboss.msc.Serviceorg.jboss.msc.service.StartExceptionpublic void stop(org.jboss.msc.service.StopContext context)
stop in interface org.jboss.msc.ServiceCopyright © 2020 JBoss by Red Hat. All rights reserved.