class procedure_kind¶
Enumeration class: the “kind” of a procedure .
The procedure_kind class corresponds to the PDG kind abstraction.
procedure_kind Members¶
| Constructors | none |
| Static Method | from_integer() |
| Methods | __cmp__(), __eq__(), __ge__(), __gt__(), __hash__(), __le__(), __lt__(), __ne__(), __repr__(), __str__(), as_integer(), name() |
| Attributes | FILE_INITIALIZATION, GENERATED_INDIRECT, HAMMOCK_GENERATED, LIBRARY, SYSTEM_INITIALIZATION, UNDEFINED, USER_DEFINED |
procedure_kind Details¶
-
class
cs.procedure_kind¶ Enumeration class: the “kind” of a
procedure.-
static
from_integer(_inner)¶ Construct an instance from an integer representation.
Parameters: _inner (int) – The integer representation, as returned by procedure_kind.as_integer().Return type: procedure_kindRaises: result.ERROR_INVALID_ARGUMENTif_inneris not a valid integer representation for aprocedure_kindinstance.Invariant: For
procedure_kindx, procedure_kind.from_integer(x.as_integer()) == x>>> pk = procedure_kind.LIBRARY.as_integer() >>> pk 3 >>> procedure_kind.from_integer(pk) <cs.procedure_kind library>
-
__cmp__(other)¶ Comparison function for
procedure_kind, with respect to a stable overall ordering.Parameters: other ( procedure_kind) – Theprocedure_kindobject to compare against.Return type: int Returns: An integer N such that: - N==0 if the two objects compare equal
- N<0 if
self< other - N>0 if
self> other
>>> procedure_kind.UNDEFINED.__cmp__(procedure_kind.SYSTEM_INITIALIZATION) -1
-
__eq__(b)¶ Equality operator for
procedure_kind.Parameters: b ( procedure_kind) – Theprocedure_kindobject to compare against.Return type: bool Returns: Trueifselfandbcompare equal,Falseotherwise.>>> procedure_kind.LIBRARY == procedure_kind.SYSTEM_INITIALIZATION False
-
__ge__(b)¶ Greater-than-or-equal operator for
procedure_kind.Parameters: b ( procedure_kind) – Theprocedure_kindobject to compare against.Return type: bool Returns: Trueifself>=b,Falseotherwise.>>> procedure_kind.UNDEFINED >= procedure_kind.HAMMOCK_GENERATED False
-
__gt__(b)¶ Greater-than operator for
procedure_kind.Parameters: b ( procedure_kind) – Theprocedure_kindobject to compare against.Return type: bool Returns: Trueifself>b,Falseotherwise.>>> procedure_kind.USER_DEFINED > procedure_kind.GENERATED_INDIRECT False
-
__hash__()¶ Hash function for
procedure_kind.Return type: int >>> hash(procedure_kind.FILE_INITIALIZATION) 5
-
__le__(b)¶ Less-than-or-equal operator for
procedure_kind.Parameters: b ( procedure_kind) – Theprocedure_kindobject to compare against.Return type: bool Returns: Trueifself<=b,Falseotherwise.>>> procedure_kind.LIBRARY <= procedure_kind.FILE_INITIALIZATION True
-
__lt__(b)¶ Less-than operator for
procedure_kind.Parameters: b ( procedure_kind) – Theprocedure_kindobject to compare against.Return type: bool Returns: Trueifself<b,Falseotherwise.>>> procedure_kind.LIBRARY < procedure_kind.UNDEFINED False
-
__ne__(b)¶ Inequality operator for
procedure_kind.Parameters: b ( procedure_kind) – Theprocedure_kindobject to compare against.Return type: bool Returns: Falseifselfandbcompare equal,Trueotherwise.>>> procedure_kind.HAMMOCK_GENERATED != procedure_kind.GENERATED_INDIRECT True
-
__repr__()¶ Get a representation of a
procedure_kindobject that includes information useful for debugging.Return type: str Returns: The string representation. >>> repr(procedure_kind.USER_DEFINED) '<cs.procedure_kind user-defined>'
-
__str__()¶ Get a simple string representation of a
procedure_kindobject.Return type: str Returns: The string representation. >>> str(procedure_kind.SYSTEM_INITIALIZATION) 'system-initialization'
-
as_integer()¶ Get an integer representation of
self.Return type: int Returns: An integer suitable for use with procedure_kind.from_integer().Invariant: For
procedure_kindx, procedure_kind.from_integer(x.as_integer()) == x>>> pk = procedure_kind.LIBRARY.as_integer() >>> pk 3 >>> procedure_kind.from_integer(pk) <cs.procedure_kind library>
-
name()¶ Get the name of a
procedure_kindobject.Return type: str Returns: The name. >>> procedure_kind.LIBRARY.name() 'library'
-
FILE_INITIALIZATION¶ Kind file-initialization
>>> procedure_kind.FILE_INITIALIZATION <cs.procedure_kind file-initialization>
-
GENERATED_INDIRECT¶ Kind generated-indirect
>>> procedure_kind.GENERATED_INDIRECT <cs.procedure_kind generated-indirect>
-
HAMMOCK_GENERATED¶ For internal use only.
>>> procedure_kind.HAMMOCK_GENERATED <cs.procedure_kind hammock-generated>
-
SYSTEM_INITIALIZATION¶ -
>>> procedure_kind.SYSTEM_INITIALIZATION <cs.procedure_kind system-initialization>
-
USER_DEFINED¶ Kind user-defined
>>> procedure_kind.USER_DEFINED <cs.procedure_kind user-defined>
-
static