Class OperatorContext
java.lang.Object
com.atgenomix.seqslab.piper.plugin.api.OperatorContext
- All Implemented Interfaces:
Serializable
An object used in pipeline operations to represent a persistent set of properties, inputs,
and outputs. An operator context object contains a list of properties in the form of NamedValue objects.
These properties represent information about the operator configuration, the environment, or the
states of pipeline operations.
An operator context object is created first from the task pipeline configuration of an input or output
data file and then calling each operator in the pipeline execution on the default and updated context.
The property keys might be fully qualified by prefixing the operator name, ex: name:key.
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionAn immutable map that contains NamedValue task input variables and files.An immutable map that contains NamedValue task output variables and files.A property map that contains NamedValue objects including those specific to the operator and other properties set by upstream pipeline operators. -
Constructor Summary
ModifierConstructorDescriptionprotected
OperatorContext
(Map<String, Object> properties) Creates an operator context with the specified defaults.protected
OperatorContext
(Map<String, Object> properties, Map<String, PiperValue> inputs) Creates an operator context with the specified defaults and task inputs.protected
OperatorContext
(Map<String, Object> properties, Map<String, PiperValue> inputs, Map<String, PiperValue> outputs) Creates an operator context with the specified defaults and task inputs and outputs. -
Method Summary
-
Field Details
-
properties
A property map that contains NamedValue objects including those specific to the operator and other properties set by upstream pipeline operators. The keys might be fully qualified by prefixing the operator name, ex: name:key. -
inputs
An immutable map that contains NamedValue task input variables and files. -
outputs
An immutable map that contains NamedValue task output variables and files.
-
-
Constructor Details
-
OperatorContext
Creates an operator context with the specified defaults.- Parameters:
properties
- default properties
-
OperatorContext
Creates an operator context with the specified defaults and task inputs.- Parameters:
properties
- default propertiesinputs
- task input variables and files
-
OperatorContext
protected OperatorContext(Map<String, Object> properties, Map<String, PiperValue> inputs, Map<String, PiperValue> outputs) Creates an operator context with the specified defaults and task inputs and outputs.- Parameters:
properties
- default propertiesinputs
- task input variables and filesoutputs
- task output variables and files
-
-
Method Details
-
get
Get the property value- Parameters:
key
- the property key- Returns:
- the property object. return null if the key is not found.
-
getProperties
Get the properties- Returns:
- the property map
-
setProperties
Set new properties
-