Interface ICurrentValueBuilder
public interface ICurrentValueBuilder
Builder for the value provided by a node while it is being executed.
- Since:
- 8.2.0
- Author:
- XIMA MEDIA GmbH
-
Method Summary
Modifier and TypeMethodDescriptionvoidprovide()Provides the configured value as the current value of the node.withAttachments(IWorkflowAttachmentValue attachments) Adds the attachments from the given value to the list of attachments made available by the node while it is being executed.default ICurrentValueBuilderwithFiles(IWorkflowFileValue files) Adds the files from the given value to the list of files made available by the node while it is being executed.Adds the files from the given value to the list of files made available by the node while it is being executed.default ICurrentValueBuilderConfigures the value returned by the node while it is being executed.withValueBuilder(IValueCreator value) Configures the value returned by the node while it is being executed.
-
Method Details
-
provide
void provide()Provides the configured value as the current value of the node. -
withAttachments
Adds the attachments from the given value to the list of attachments made available by the node while it is being executed.- Parameters:
attachments- Value containing the attachments to be made available.- Returns:
- This builder for chaining methods calls.
-
withFiles
Adds the files from the given value to the list of files made available by the node while it is being executed.- Parameters:
files- Value containing the files to be made available.- Returns:
- This builder for chaining methods calls.
-
withFilesBuilder
Adds the files from the given value to the list of files made available by the node while it is being executed.- Parameters:
files- Value containing the files to be made available.- Returns:
- This builder for chaining methods calls.
-
withValue
Configures the value returned by the node while it is being executed. When this method is not called, the default value from theIExecutionResultDescriptor.getCurrentValueDescriptor(IValueDescriptorFactory)is used. When this method is called multiple times, behaves as ifIValueBuilder.value(Object)were called multiple times.- Parameters:
value- Value made available when the node is being executed.- Returns:
- This builder for chaining methods calls.
-
withValueBuilder
Configures the value returned by the node while it is being executed. When this method is not called, the default value from theIExecutionResultDescriptor.getCurrentValueDescriptor(IValueDescriptorFactory)is used.When this method is called multiple times, behaves as if
IValueBuilderwere manipulated multiple times with the given configurator. The value is reset between loop executions. UseINodeExecutionParams.resetCurrentValue()to reset the builder manually.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:
value- Function that takes a value builder to create the value.- Returns:
- This builder for chaining methods calls.
-