Class OperationFunction<T,V>
- java.lang.Object
-
- org.jboss.as.clustering.controller.OperationFunction<T,V>
-
- Type Parameters:
T- the type of value provided by the service on which the given runtime operation operatesV- the type of the value of which the given runtime operation operates
- All Implemented Interfaces:
org.wildfly.common.function.ExceptionFunction<T,org.jboss.dmr.ModelNode,org.jboss.as.controller.OperationFailedException>
public class OperationFunction<T,V> extends Object implements org.wildfly.common.function.ExceptionFunction<T,org.jboss.dmr.ModelNode,org.jboss.as.controller.OperationFailedException>
A functional view of a runtime operation.- Author:
- Paul Ferraro
-
-
Constructor Detail
-
OperationFunction
public OperationFunction(org.jboss.as.controller.ExpressionResolver resolver, org.jboss.dmr.ModelNode operation, Function<T,V> mapper, Operation<V> executable)Creates a functional view of the specified metric using the specified mapping function.- Parameters:
resolver- an expression resolveroperation- the management operationmapper- maps the value of a service to the value on which the given metric operatesexecutable- a runtime operation
-
-
Method Detail
-
apply
public org.jboss.dmr.ModelNode apply(T value) throws org.jboss.as.controller.OperationFailedException
- Specified by:
applyin interfaceorg.wildfly.common.function.ExceptionFunction<T,org.jboss.dmr.ModelNode,org.jboss.as.controller.OperationFailedException>- Throws:
org.jboss.as.controller.OperationFailedException
-
-