wrapper
xsdata.formats.dataclass.parsers.nodes.wrapper
WrapperNode
Bases: XmlNode
XmlNode for wrapper class fields.
This node represents wrap class fields, that don't actually appear in the serialized document.
These fields simplify classes and this kind of node simply proxies the child requests to the parent node.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
parent | ElementNode | The parent node | required |
Attributes:
Name | Type | Description |
---|---|---|
ns_map | The node namespace prefix-URI map |
Source code in xsdata/formats/dataclass/parsers/nodes/wrapper.py
7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 |
|
bind(qname, text, tail, objects)
This node will never appear in the xml, so it never binds any data.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
qname | str | The element qualified name | required |
text | Optional[str] | The element text content | required |
tail | Optional[str] | The element tail content | required |
objects | List | The list of intermediate parsed objects | required |
Returns:
Type | Description |
---|---|
bool | Always false because no binding takes place. |
Source code in xsdata/formats/dataclass/parsers/nodes/wrapper.py
28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 |
|
child(qname, attrs, ns_map, position)
Proxy the next child node to the parent node.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
qname | str | The element qualified name | required |
attrs | Dict | The element attributes | required |
ns_map | Dict | The element namespace prefix-URI map | required |
position | int | The current length of the intermediate objects | required |
Returns:
Type | Description |
---|---|
XmlNode | The child xml node instance. |
Source code in xsdata/formats/dataclass/parsers/nodes/wrapper.py
44 45 46 47 48 49 50 51 52 53 54 55 56 |
|