Home | Trees | Index | Help |
|
---|
Package lxml :: Module etree :: Class EntityBase |
|
object
--+ |_Element
--+ |__ContentOnlyElement
--+ |_Entity
--+ | EntityBase
HtmlEntity
All custom Entity classes must inherit from this one.
Note that subclasses *must not* override __init__ or __new__ as it is absolutely undefined when these objects will be created or destroyed. All persistent state of Entities must be stored in the underlying XML. If you really need to initialize the object after creation, you can implement an ``_init(self)`` method that will be called after object creation.Method Summary | |
---|---|
T.__new__(S, ...) -> a new object with type S, a subtype of T | |
Inherited from _Entity | |
x.__repr__() <==> repr(x) | |
Inherited from __ContentOnlyElement | |
x.__delitem__(y) <==> del x[y] | |
Use of negative indices is not supported. | |
x.__getitem__(y) <==> x[y] | |
x.__len__() <==> len(x) | |
x.__setitem__(i, y) <==> x[i]=y | |
Use of negative indices is not supported. | |
| |
| |
| |
| |
| |
| |
| |
Inherited from _Element | |
x.__contains__(y) <==> y in x | |
| |
| |
Use of negative indices is not supported. | |
x.__iter__() <==> iter(x) | |
x.__nonzero__() <==> x != 0 | |
| |
Called after object initialisation. | |
Adds the element as a following sibling directly after this element. | |
Adds the element as a preceding sibling directly before this element. | |
Resets an element. | |
Extends the current children by the elements in the iterable. | |
Finds the first matching subelement, by tag name or path. | |
Finds all matching subelements, by tag name or path. | |
Finds text for the first matching subelement, by tag name or path. | |
Returns all subelements. | |
Iterate over all elements in the subtree in document order (depth first pre-order), starting with this element. | |
Returns the following sibling of this element or None. | |
Returns the parent of this element or None for the root element. | |
Returns the preceding sibling of this element or None. | |
Return an ElementTree for the root node of the document that contains this element. | |
Find the position of the child within the parent. | |
Iterate over all elements in the subtree in document order (depth first pre-order), starting with this element. | |
Iterate over the ancestors of this element (from parent to parent). | |
Iterate over the children of this element. | |
Iterate over the descendants of this element in document order. | |
Iterate over the following or preceding siblings of this element. | |
Creates a new element associated with the same document. | |
Removes a matching subelement. | |
Replaces a subelement with the element passed as second argument. | |
Evaluate an xpath expression using the element as context node. | |
Inherited from object | |
x.__init__(...) initializes x; see x.__class__.__doc__ for signature | |
x.__delattr__('name') <==> del x.name | |
x.__getattribute__('name') <==> x.name | |
x.__hash__() <==> hash(x) | |
helper for pickle | |
helper for pickle | |
x.__setattr__('name', value) <==> x.name = value | |
x.__str__() <==> str(x) |
Class Variable Summary | |
---|---|
PyCObject |
__pyx_vtable__ = <PyCObject object at 0x401cb818>
|
Inherited from _Entity | |
getset_descriptor |
name = <attribute 'name' of 'lxml.etree._Entity' objects...
|
getset_descriptor |
tag = <attribute 'tag' of 'lxml.etree._Entity' objects>
|
Inherited from __ContentOnlyElement | |
getset_descriptor |
attrib = <attribute 'attrib' of 'lxml.etree.__ContentOnl...
|
getset_descriptor |
text = <attribute 'text' of 'lxml.etree.__ContentOnlyEle...
|
Inherited from _Element | |
getset_descriptor |
nsmap = <attribute 'nsmap' of 'lxml.etree._Element' obje...
|
getset_descriptor |
prefix = <attribute 'prefix' of 'lxml.etree._Element' ob...
|
getset_descriptor |
sourceline = <attribute 'sourceline' of 'lxml.etree._Ele...
|
getset_descriptor |
tail = <attribute 'tail' of 'lxml.etree._Element' object...
|
Method Details |
---|
__new__(T, S, ...)T.__new__(S, ...) -> a new object with type S, a subtype of T
|
Class Variable Details |
---|
__pyx_vtable__
|
Home | Trees | Index | Help |
|
---|
Generated by Epydoc 2.1 on Sat Aug 18 12:44:28 2007 | http://epydoc.sf.net |