Assembly: OptimaJet.Workflow.Core

Interface IParameterBuilder

OptimaJet.Workflow.Core.Model.Builder.IParameterBuilder

Provides fluent configuration for an explicit process parameter in a ProcessDefinition.

public interface IParameterBuilder : IProcessDefinitionBuilder

Type Hierarchy

Methods

IParameterBuilder Ref(out ParameterDefinition parameterDefinition) #
Assigns the current ParameterDefinition to parameterDefinition.

Parameters

Name
Type
Description
parameterDefinition
ParameterDefinition
Receives the ParameterDefinition being configured.

Returns

Type
Description
IParameterBuilder
The current IParameterBuilder instance for method chaining.
IParameterBuilder Name(string name) #
Sets the process parameter name of the current ParameterDefinition.

Parameters

Name
Type
Description
name
String
The process parameter name.

Returns

Type
Description
IParameterBuilder
The current IParameterBuilder instance for method chaining.
IParameterBuilder Purpose(ParameterPurpose purpose) #
Sets ParameterDefinition.Purpose for the current process parameter.

Parameters

Name
Type
Description
purpose
ParameterPurpose
The ParameterPurpose that controls how Workflow Engine manages and stores the parameter.

Returns

Type
Description
IParameterBuilder
The current IParameterBuilder instance for method chaining.

Exceptions

Type
Description
InvalidOperationException
IParameterBuilder Type(Type type) #
Sets ParameterDefinition.Type for the current process parameter.

Parameters

Name
Type
Description
type
Type
The CLR Type used for parameter values.

Returns

Type
Description
IParameterBuilder
The current IParameterBuilder instance for method chaining.

Exceptions

Type
Description
InvalidOperationException
The existing ParameterDefinition.InitialValue cannot be deserialized as type.
IParameterBuilder InitialValue(string initialValue) #
Sets ParameterDefinition.InitialValue from its stored string representation.

Parameters

Name
Type
Description
initialValue
String
The value to store. For a parameter whose ParameterDefinition.Type is not string, the value must be valid JSON that can be deserialized as that type.

Returns

Type
Description
IParameterBuilder
The current IParameterBuilder instance for method chaining.

Exceptions

Type
Description
InvalidOperationException
The current ParameterDefinition.Purpose is not ParameterPurpose.Persistence, or initialValue cannot be deserialized as the current ParameterDefinition.Type.
IParameterBuilder InitialValue(object initialValue) #
Serializes initialValue and stores the result in ParameterDefinition.InitialValue.

Parameters

Name
Type
Description
initialValue
Object
The value to serialize. Its runtime type must be compatible with the current ParameterDefinition.Type.

Returns

Type
Description
IParameterBuilder
The current IParameterBuilder instance for method chaining.

Exceptions

Type
Description
InvalidOperationException
The current ParameterDefinition.Purpose is not ParameterPurpose.Persistence, or initialValue is not an instance of the current ParameterDefinition.Type.
IParameterBuilder ClearInitialValue() #
Clears ParameterDefinition.InitialValue for the current process parameter.

Returns

Type
Description
IParameterBuilder
The current IParameterBuilder instance for method chaining.