Package pyxb :: Package xmlschema :: Module structures :: Class _AttributeWildcard_mixin |
[hide private]
[frames] | no frames]

# type _AttributeWildcard_mixin

source code

    object --+
             |
       cscRoot --+
                 |
                _AttributeWildcard_mixin

Known Subclasses:
  - AttributeGroupDefinition
  - , ComplexTypeDefinition

Support for components that accept attribute wildcards.

That is AttributeGroupDefinition and ComplexTypeDefinition. The calculations of the appropriate wildcard are sufficiently complex that they need to be abstracted out to a mix-in class.

Instance Methods | [hide private]
attributeWildcard(self) Return the Wildcard component associated with attributes of this instance, or `None` if attribute wildcards are not present in the instance. | source code
_setAttributeWildcard(self, attribute_wildcard) Set the attribute wildcard property for this instance. | source code
_attributeRelevantChildren(self, node_list) Return the nodes that are relevant for attribute processing. | source code
Inherited from `cscRoot`: `__init__`

Class Methods | [hide private]
CompleteWildcard(cls, namespace_context, attribute_groups, local_wildcard) Implement the algorithm as described the specification. | source code

Class Variables | [hide private]
| __attributeWildcard = `None`
| _AttributeWildcard_mixin__attributeWildcard = `None`

Method Details | [hide private]

### _attributeRelevantChildren(self, node_list) | source code
Return the nodes that are relevant for attribute processing. Parameters: `node_list` - A sequence of nodes found in a definition content information item. Returns: A tuple `( attributes, attributeGroups, attributeWildcard)` where `attributes` is the subsequence of `node_list` that are XMLSchema `attribute` nodes; `attributeGroups` is analogous; and `attributeWildcard` is a single DOM node with XMLSchema name `anyAttribute` (or `None`, if no such node is present in the list). Raises: `pyxb.SchemaValidationError` - An `attributeGroup` node is present but does not have the required `ref` attribute. `pyxb.SchemaValidationError` - Multiple `anyAttribute` nodes are identified.

### CompleteWildcard(cls, namespace_context, attribute_groups, local_wildcard) Class Method | source code
Implement the algorithm as described the specification. Parameters: `namespace_context` - The pyxb.namespace.NamespaceContext to be associated with any created Wildcard instance `attribute_groups` - A list of AttributeGroupDefinition instances `local_wildcard` - A Wildcard instance computed from a relevant XMLSchema `anyAttribute` element, or `None` if no attribute wildcard is relevant