ecflow.RepeatEnumerated

class ecflow.RepeatEnumerated

Bases: pybind11_object

Allows a node to be repeated using a enumerated list.

A node can only have one repeat. The repeat can be referenced in trigger expressions.

Constructor:

RepeatEnumerated(variable,list)
   string variable:     The name of the repeat. The current enumeration index can be
                        referenced in trigger expressions using the variable name
   vector list:         The list of enumerations

Usage:

t = Task('t1',
         RepeatEnumerated('COLOR', [ 'red', 'green', 'blue' ] ))

Accessor methods:

current_index() -> int
   Zero-based index of the current enumeration value.
current_value() -> str
   The enumeration string at the current index, or '' if out of bounds.
RepeatEnumerated.current_index(self: ecflow.RepeatEnumerated) int

Return the zero-based index of the current enumeration value.

RepeatEnumerated.current_value(self: ecflow.RepeatEnumerated) object

Return the enumeration string at the current index.

RepeatEnumerated.end(self: ecflow.RepeatEnumerated) int
RepeatEnumerated.name(self: ecflow.RepeatEnumerated) str

Return the name of the repeat.

RepeatEnumerated.start(self: ecflow.RepeatEnumerated) int
RepeatEnumerated.step(self: ecflow.RepeatEnumerated) int