type CF_enumeration
source code
object --+
|
cscRoot --+
|
Facet --+
|
ConstrainingFacet --+
|
object --+ |
| |
cscRoot --+ |
| |
_CollectionFacet_mixin --+
|
object --+ |
| |
cscRoot --+ |
| |
_LateDatatype_mixin --+
|
CF_enumeration
Capture a constraint that restricts valid values to a fixed set.
A STD that has an enumeration restriction should mix-in pyxb.binding.basis.enumeration_mixin, and should have a
class variable titled _CF_enumeration
that is an instance of
this class.
"unicode" refers to the Unicode string by which the value is
represented in XML.
"tag" refers to the Python member reference associated with
the enumeration. The value is derived from the unicode value of the
enumeration element and an optional prefix that identifies the owning
simple type when the tag is promoted to module-level visibility.
"value" refers to the Python value held in the tag
See http://www.w3.org/TR/xmlschema-2/#rf-enumeration
|
_Name = ' enumeration '
|
|
_LateDatatypeBindsSuperclass = False
The class variable that indicates that the Subclasses must override
this variable with a value of True or
False .
|
|
__tagToElement = None
|
|
__valueToElement = None
|
|
__unicodeToElement = None
|
|
__enumPrefix = None
|
Inherited from ConstrainingFacet :
Facets
|
Create a facet instance, initializing it from the keyword
parameters.
- Overrides:
cscRoot.__init__
|
Return the _EnumerationElement instance that has the
given value.
- Raises:
KeyError - the value is not valid for the enumeration.
|
Return the enumeration value corresponding to the given unicode
string.
If ustr is not a valid option for this enumeration, return None.
|