Package lxml :: Module etree :: Class _IDDict

[hide private]
[frames] | no frames]

# Class _IDDict

    object --+
             |
            _IDDict

IDDict(self, etree) A dictionary-like proxy class that mapps ID attributes to elements.

The dictionary must be instantiated with the root element of a parsed XML document, otherwise the behaviour is undefined. Elements and XML trees that were created or modified 'by hand' are not supported.

Instance Methods | [hide private]

__contains__(x, y) y in x |

__getitem__(...) |

__init__(self, etree) x.__init__(...) initializes x; see x.__class__.__doc__ for signature |

__iter__(...) |

__len__(x) len(x) |

a new object with type S, a subtype of T

__new__(T, S, ...) |

__repr__(...) repr(x) |

copy(...) |

get(...) |

has_key(...) |

items(...) |

iteritems(...) |

iterkeys(...) |

itervalues(...) |

keys(...) |

values(...) |

Inherited from `object`: `__delattr__`, `__format__`, `__getattribute__`, `__hash__`, `__reduce__`, `__reduce_ex__`, `__setattr__`, `__sizeof__`, `__str__`, `__subclasshook__`

Properties | [hide private]

Inherited from `object`: `__class__`

Method Details | [hide private]

### __init__(self, etree)
(Constructor)

x.__init__(...) initializes x; see x.__class__.__doc__ for signature

Overrides: object.__init__

### __new__(T, S, ...)

Returns: a new object with type S, a subtype of T
Overrides: object.__new__

### __repr__(...)
(Representation operator)

repr(x)

Overrides: object.__repr__
  (inherited documentation)