Interface IWorkflowNodeResult
- All Known Implementing Classes:
WorkflowNodeResult
public interface IWorkflowNodeResult
Represents the result obtained when a workflow node was executed. The execution may have
- completed normally, in which case
getNormalCompletionResult()is available - completed abruptly by throwing an exception, in which case
getAbruptCompletionException()is available and returns aNodeThrewException. - completed abruptly by requesting a return, in which case
getAbruptCompletionException()is available and returns aNodeReturnedException.
- Since:
- 7.0.0
- Author:
- XIMA MEDIA GmbH
-
Method Summary
Modifier and TypeMethodDescriptiondefault Objectdefault IWorkflowAttachmentValuedefault List<? extends IErrorResultData>default IWorkflowFileValuedefault WorkflowNodegetNode()Finds the workflow node that created this result.default NodeReturnedExceptiondefault List<NodeSoftErrorException>default ISuccessResultDatadefault Objectdefault NodeThrewExceptiondefault booleanChecks whether a hard error occurred during the node's execution, i.e. whether the node completed abruptly by throwing an exception.default booleanChecks whether any soft errors occurred during the node's execution, i.e. whether the node completed normally or by issuing a return statements and at least one soft error was provided.default booleanChecks whether any error occurred during the node's execution, including hard and soft errors.default booleanChecks whether the node was executed successfully, i.e. whether it completed normally or by issuing a return statement.
-
Method Details
-
getAbruptCompletionException
- Returns:
- The exception that was thrown by the workflow node, or
nullwhen the node did not complete abruptly. - See Also:
-
getAlwaysResultValue
- Returns:
- The value of the result that is always available. May be
nullif the node provides no result.
-
getAttachmentValue
- Returns:
- If
isWasSuccessful()istrue, this returns the attachments created by the node when it was executed successfully.
-
getCompletionType
ENodeCompletionType getCompletionType()- Returns:
- How the execution of the workflow node completed.
-
getErrorResultData
- Returns:
- Returns a list of error results provided by the node. When
isWasSuccessful()istrue, this returns thesoft errors. Otherwise, whenisWasSuccessful()isfalse, this returns a singleton list withgetThrowingException(). - Since:
- 7.0.7
-
getFileValue
- Returns:
- If
isWasSuccessful()istrue, this returns the files created by the node when it was executed successfully.
-
getNode
Finds the workflow node that created this result.- Returns:
- The workflow node that creates this result.
-
getNormalCompletionResult
- Returns:
- The result returned by the workflow node upon execution, or
nullwhen the node did not complete normally. - See Also:
-
getReturningException
- Returns:
- The
NodeReturnedExceptionwhengetCompletionType()isENodeCompletionType.RETURNING, ornullotherwise.
-
getSoftErrors
- Returns:
- If
isWasSuccessful()istrue, this returns the soft errors provided by the node when it was executed successfully. Returns an empty list whenisWasSuccessful()isfalseor the node did not provide any soft errors. - Since:
- 7.0.7
-
getSuccessResultData
- Returns:
- If
isWasSuccessful()istrue, this returns the success result data obtained by the node when it was executed successfully. ReturnsnullwhenisWasSuccessful()isfalse. - Since:
- 7.0.7
-
getSuccessResultValue
- Returns:
- If
isWasSuccessful()istrue, this returns the result obtained by the node when it was executed successfully. ReturnsnullwhenisWasSuccessful()isfalseor the node provided no result.
-
getThrowingException
- Returns:
- The
NodeThrewExceptionwhengetCompletionType()isENodeCompletionType.THROWING, ornullotherwise.
-
isHasHardError
default boolean isHasHardError()Checks whether a hard error occurred during the node's execution, i.e. whether the node completed abruptly by throwing an exception. This is the opposite ofisWasSuccessful().- Returns:
- Whether the node threw a
NodeThrewException. - Since:
- 7.0.7
- See Also:
-
isHasSoftErrors
default boolean isHasSoftErrors()Checks whether any soft errors occurred during the node's execution, i.e. whether the node completed normally or by issuing a return statements and at least one soft error was provided.- Returns:
- Whether the node provided at least one soft error.
- Since:
- 7.0.7
- See Also:
-
isHasSoftOrHardErrors
default boolean isHasSoftOrHardErrors()Checks whether any error occurred during the node's execution, including hard and soft errors. That is, returnsfalsewhen either the node completed abruptly by throwing an exception; or when the node completed normally or by issuing a return statement and at least one soft error is present.- Returns:
- Whether any soft or hard errors occurred during the node's execution.
- Since:
- 7.0.7
- See Also:
-
isWasSuccessful
default boolean isWasSuccessful()Checks whether the node was executed successfully, i.e. whether it completed normally or by issuing a return statement. When this returnstrue,getSuccessResultValue()is available. When this returnsfalse,getThrowingException()is available.Note: This is the opposite of
isHasHardError(). This method checks for a hard error, i.e. whether the node threw an exception or not, it does not check forsoft errors.- Returns:
- Whether the node was executed successfully.
- See Also:
-