Interface IWorkflowNodeResult

All Known Implementing Classes:
WorkflowNodeResult

public interface IWorkflowNodeResult
Represents the result obtained when a workflow node was executed. The execution may have
Since:
7.0.0
Author:
XIMA MEDIA GmbH
  • Method Details

    • getAbruptCompletionException

      @Nullable AbstractAbruptCompletionException getAbruptCompletionException()
      Returns:
      The exception that was thrown by the workflow node, or null when the node did not complete abruptly.
      See Also:
    • getAlwaysResultValue

      default Object getAlwaysResultValue()
      Returns:
      The value of the result that is always available. May be null if the node provides no result.
    • getAttachmentValue

      default IWorkflowAttachmentValue getAttachmentValue()
      Returns:
      If isWasSuccessful() is true, this returns the attachments created by the node when it was executed successfully.
    • getCompletionType

      ENodeCompletionType getCompletionType()
      Gets the type of how the node completed when it was executed.
      Returns:
      How the execution of the workflow node completed.
    • getErrorResultData

      default List<? extends IErrorResultData> getErrorResultData()
      Returns:
      Returns a list of error results provided by the node. When isWasSuccessful() is true, this returns the soft errors. Otherwise, when isWasSuccessful() is false, this returns a singleton list with getThrowingException().
      Since:
      7.0.7
    • getFileValue

      default IWorkflowFileValue getFileValue()
      Returns:
      If isWasSuccessful() is true, this returns the files created by the node when it was executed successfully.
    • getNode

      default WorkflowNode getNode()
      Finds the workflow node that created this result.
      Returns:
      The workflow node that creates this result.
    • getNormalCompletionResult

      @Nullable INormalCompletionResult getNormalCompletionResult()
      Returns:
      The result returned by the workflow node upon execution, or null when the node did not complete normally.
      See Also:
    • getReturningException

      @Nullable default NodeReturnedException getReturningException()
      Returns:
      The NodeReturnedException when getCompletionType() is ENodeCompletionType.RETURNING, or null otherwise.
    • getSoftErrors

      default List<NodeSoftErrorException> getSoftErrors()
      Returns:
      If isWasSuccessful() is true, this returns the soft errors provided by the node when it was executed successfully. Returns an empty list when isWasSuccessful() is false or the node did not provide any soft errors.
      Since:
      7.0.7
    • getSuccessResultData

      @Nullable default ISuccessResultData getSuccessResultData()
      Returns:
      If isWasSuccessful() is true, this returns the success result data obtained by the node when it was executed successfully. Returns null when isWasSuccessful() is false.
      Since:
      7.0.7
    • getSuccessResultValue

      @Nullable default Object getSuccessResultValue()
      Returns:
      If isWasSuccessful() is true, this returns the result obtained by the node when it was executed successfully. Returns null when isWasSuccessful() is false or the node provided no result.
    • getThrowingException

      @Nullable default NodeThrewException getThrowingException()
      Returns:
      The NodeThrewException when getCompletionType() is ENodeCompletionType.THROWING, or null otherwise.
    • getTransferringControlException

      @Nullable default NodeTransferredControlException getTransferringControlException()
      Returns:
      The NodeTransferredControlException when getCompletionType() is ENodeCompletionType.TRANSFERRING_CONTROL, or null otherwise.
      Since:
      8.1.0
    • isAbruptlyCompleted

      default boolean isAbruptlyCompleted()
      Checks if the node completed abruptly. The difference to isWasSuccessful() is that control transfer and returning abrupt completions are considered successful.
      Returns:
      true if the node completed abruptly in any manner, false otherwise.
      Since:
      8.1.0
    • 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 of isWasSuccessful().
      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, returns false when 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:
    • isNormallyCompleted

      default boolean isNormallyCompleted()
      Checks if the node completed normally. The difference to isWasSuccessful() is that control transfer and returning abrupt completions are considered successful.
      Returns:
      true if the node completed normally, false otherwise.
      Since:
      8.1.0
    • 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 returns true, getSuccessResultValue() is available. When this returns false, 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 for soft errors.

      Returns:
      Whether the node was executed successfully.
      See Also: