biocrnpyler.core.ParameterKey
- class biocrnpyler.core.ParameterKey(mechanism, part_id, name)[source]
Bases:
ParameterKeyNamed tuple defining a parameter key.
- Parameters:
mechanism (
str,Mechanism, orNone) – Mechanism identifier. Can be a string (used as both name and type), a Mechanism object (uses .name and .mechanism_type), or None.part_id (
strorNone) – Part/component identifier for the parameter.name (
str) – Name of the parameter. Must start with a letter and contain at least one character.
Methods
Return number of occurrences of value.
Return first index of value.
- __add__(value, /)
Return self+value.
- classmethod __class_getitem__(object, /)
Tuples are generic over the types of their contents.
For example, use
tuple[int, str]for a pair whose first element is an int and second element is a string.Tuples also support the form
tuple[T, ...]to indicate an arbitrary length tuple of elements of type T.
- __contains__(key, /)
Return bool(key in self).
- __eq__(value, /)
Return self==value.
- __ge__(value, /)
Return self>=value.
- __getattribute__(name, /)
Return getattr(self, name).
- __getitem__(key, /)
Return self[key].
- __getnewargs__()
Return self as a plain tuple. Used by copy and pickle.
- __gt__(value, /)
Return self>value.
- __iter__(/)
Implement iter(self).
- __le__(value, /)
Return self<=value.
- __len__(/)
Return len(self).
- __lt__(value, /)
Return self<value.
- __mul__(value, /)
Return self*value.
- __ne__(value, /)
Return self!=value.
- static __new__(_cls, mechanism, part_id, name)
Create new instance of ParameterKey(mechanism, part_id, name)
- __replace__(**kwds)
Return a new ParameterKey object replacing specified fields with new values
- __rmul__(value, /)
Return value*self.
- count(value, /)
Return number of occurrences of value.
- index(value, start=0, stop=sys.maxsize, /)
Return first index of value.
Raises ValueError if the value is not present.
- mechanism
Alias for field number 0
- name
Alias for field number 2
- part_id
Alias for field number 1