class documentation

Resource attribute cardinalities.

Class Method hasCar Check whether an Cardinality without the 'car' prefix exists.
Class Method isMandatory Check whether a Cardinality is mandatory.
Class Method to Convert a cardinality name string to an enum value.
Constant CAR01 Optional.
Constant CAR01L Optional list.
Constant CAR1 Mandatory.
Constant CAR1L Mandatory list.
Constant CAR1LN Mandatory list that shall not be empty.
Constant CAR1N Mandatory but may be Null/None.

Inherited from ACMEIntEnum:

Class Method has Check whether the enum type has an entry with either the given int value or string name.
Method __int__ Get the integer value of an enum.
Method __repr__ Stringify an enum.
Method __str__ Stringify an enum.
@classmethod
def hasCar(cls, name: str) -> bool:

Check whether an Cardinality without the 'car' prefix exists.

Example

hasCar('01')

Parameters
name:strCardinality.
Returns
boolRetun True if the cardinality exists.
@classmethod
def isMandatory(cls, car: Cardinality) -> bool:

Check whether a Cardinality is mandatory.

Parameters
car:CardinalityCardinality to check.
Returns
boolTrue if the Cardinality is of mandatory kind.
@classmethod
def to(cls, name: str | tuple[str], insensitive: bool | None = True) -> Cardinality:

Convert a cardinality name string to an enum value.

Parameters
name:str | tuple[str]String or a Tuple of strings with names.
insensitive:bool | NoneWhether to handle the name case-insensitive.
Returns
CardinalityEnum value.
CAR01 =

Optional.

Value
auto()
CAR01L =

Optional list.

Value
auto()
CAR1 =

Mandatory.

Value
auto()
CAR1L =

Mandatory list.

Value
auto()
CAR1LN =

Mandatory list that shall not be empty.

Value
auto()
CAR1N =

Mandatory but may be Null/None.

Value
auto()