concepts.dm.crow.behavior_utils.ApplicableBehaviorItem#
- class ApplicableBehaviorItem[source]#
Bases:
NamedTuple
A behavior item that is applicable to the given goal.
Methods
count
(value, /)Return number of occurrences of value.
index
(value[, start, stop])Return first index of value.
Attributes
The behavior that is applicable.
The bounded variables that are used to instantiate the behavior.
Whether the behavior should be executed in deferred mode.
- __add__(value, /)#
Return self+value.
- __getitem__(key, /)#
Return self[key].
- __init__()#
- __iter__()#
Implement iter(self).
- __len__()#
Return len(self).
- __mul__(value, /)#
Return self*value.
- static __new__(_cls, behavior, bounded_variables, defered_execution=False)#
Create new instance of ApplicableBehaviorItem(behavior, bounded_variables, defered_execution)
- Parameters:
behavior (CrowBehavior)
bounded_variables (Dict[str, Variable | ObjectConstant | TensorValue] | Dict[str, ObjectOrValueOutputExpression])
defered_execution (bool)
- count(value, /)#
Return number of occurrences of value.
- index(value, start=0, stop=9223372036854775807, /)#
Return first index of value.
Raises ValueError if the value is not present.
- behavior: CrowBehavior#
The behavior that is applicable.
- bounded_variables: Dict[str, Variable | ObjectConstant | TensorValue] | Dict[str, ObjectOrValueOutputExpression]#
The bounded variables that are used to instantiate the behavior. If deferred_execution is True, the values are ObjectOrValueOutputExpression, otherwise Variable or ObjectConstant.