Package org.jboss.as.protocol.mgmt
Interface ActiveOperation.ResultHandler<T>
-
- Type Parameters:
T- the result type
- Enclosing interface:
- ActiveOperation<T,A>
public static interface ActiveOperation.ResultHandler<T>Handler for the operation result or to mark the operation as cancelled or failed.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidcancel()Cancel the operation.booleandone(T result)Set the result.booleanfailed(Throwable t)Mark the operation as failed.
-
-
-
Method Detail
-
done
boolean done(T result)
Set the result.- Parameters:
result- the result- Returns:
trueif the result was successfully set, orfalseif a result was already set
-
failed
boolean failed(Throwable t)
Mark the operation as failed.- Parameters:
t- the exception- Returns:
trueif the result was successfully set, orfalseif a result was already set
-
cancel
void cancel()
Cancel the operation.
-
-