Interface ICompletionResultBuilder<TBuilder,​TResult>

    • Method Summary

      All Methods Instance Methods Abstract Methods Default Methods 
      Modifier and Type Method Description
      TBuilder always​(IValueCreator<?> alwaysValue)
      Sets (replaces) the value made available by the node regardless of whether it was executed successfully (or threw an exception).
      default TBuilder always​(Object alwaysValue)
      Sets (replaces) the value made available by the node regardless of whether it was executed successfully (or threw an exception).
      TBuilder file​(IWorkflowFileValue fileValue)
      Sets (replaces) the files made available by the plugin when it was executed successfully.
      default TBuilder file​(File... files)
      Sets (replaces) the files made available by the plugin when it was executed successfully.
      default TBuilder file​(Iterable<File> files)
      Sets (replaces) the files made available by the plugin when it was executed successfully.
      • Methods inherited from interface org.apache.commons.lang3.builder.Builder

        build
    • Method Detail

      • always

        TBuilder always​(IValueCreator<?> alwaysValue)
        Sets (replaces) the value made available by the node regardless of whether it was executed successfully (or threw an exception). When this method is not called, the default value from the IExecutionResultDescriptor.getAlwaysValueDescriptor(IValueDescriptorFactory) is used. When this method is called multiple times, only the value supplied by the last invocation is used.

        For example, when you wish to return a record with two properties:

         // Corresponds to the JSON object {"foo": "bar", "baz": 42}
         builder.success(b -> b.asRecord().property("foo", "bar").property("baz", 42);
         
        Parameters:
        alwaysValue - Function that takes a value builder to create the value.
        Returns:
        This builder for chaining methods calls.
      • always

        default TBuilder always​(Object alwaysValue)
        Sets (replaces) the value made available by the node regardless of whether it was executed successfully (or threw an exception). When this method is not called, the default value from the IExecutionResultDescriptor.getAlwaysValueDescriptor(IValueDescriptorFactory) is used. When this method is called multiple times, only the value supplied by the last invocation is used.
        Parameters:
        alwaysValue - Value made available by the plugin when it was executed.
        Returns:
        This builder for chaining methods calls.
      • file

        default TBuilder file​(File... files)
        Sets (replaces) the files made available by the plugin when it was executed successfully. When this method is not called, the default value from the IExecutionResultDescriptor.getFileValueDescriptor() is used. When this method i@Override s called multiple times, only the value supplied by the last invocation is used.
        Parameters:
        files - File or files supplied by the plugin.
        Returns:
        This builder for chaining methods calls.
      • file

        default TBuilder file​(Iterable<File> files)
        Sets (replaces) the files made available by the plugin when it was executed successfully. When this method is not called, the default value from the IExecutionResultDescriptor.getFileValueDescriptor() is used. When this method is called multiple times, only the value supplied by the last invocation is used.
        Parameters:
        files - File or files supplied by the plugin.
        Returns:
        This builder for chaining methods calls.
      • file

        TBuilder file​(IWorkflowFileValue fileValue)
        Sets (replaces) the files made available by the plugin when it was executed successfully. When this method is not called, the default value from the IExecutionResultDescriptor.getFileValueDescriptor() is used. When this method is called multiple times, only the value supplied by the last invocation is used.
        Parameters:
        fileValue - File or files supplied by the plugin.
        Returns:
        This builder for chaining methods calls.