Package dns :: Module namedict :: Class NameDict |
[hide private]
[frames] | no frames]

# Class NameDict

source code

           object --+
                    |
        _abcoll.Sized --+
                        |
           object --+   |
                    |   |
     _abcoll.Iterable --+
                        |
           object --+   |
                    |   |
    _abcoll.Container --+
                        |
          _abcoll.Mapping --+
                            |
       _abcoll.MutableMapping --+
                                |
                               NameDict

A dictionary whose keys are dns.name.Name objects.

Nested Classes | [hide private]
Inherited from `_abcoll.Sized`: `__metaclass__`

Instance Methods | [hide private]
__init__(self, *args, **kwargs) x.__init__(...) initializes x; see help(type(x)) for signature | source code
__update_max_depth(self, key) | source code
__getitem__(self, key) | source code
__setitem__(self, key, value) | source code
__delitem__(self, key) | source code
__iter__(self) | source code
__len__(self) | source code
has_key(self, key) | source code
(key, value) tuple |
get_deepest_match(self, name) Find the deepest match to name in the dictionary. | source code
Inherited from `_abcoll.MutableMapping`: `clear`, `pop`, `popitem`, `setdefault`, `update` Inherited from `_abcoll.Mapping`: `__contains__`, `__eq__`, `__ne__`, `get`, `items`, `iteritems`, `iterkeys`, `itervalues`, `keys`, `values` Inherited from `object`: `__delattr__`, `__format__`, `__getattribute__`, `__new__`, `__reduce__`, `__reduce_ex__`, `__repr__`, `__setattr__`, `__sizeof__`, `__str__`

Class Methods | [hide private]
Inherited from `_abcoll.Sized`: `__subclasshook__`

Class Variables | [hide private]
| __abstractmethods__ = ``frozenset([``])``
| _abc_negative_cache = `<_weakrefset.WeakSet object at 0x103d34750>`
| _abc_negative_cache_version = `23`
| _abc_registry = `<_weakrefset.WeakSet object at 0x103d345d0>`
Inherited from `_abcoll.Mapping`: `__hash__` Inherited from `_abcoll.Sized` (private): `_abc_cache`

Instance Variables | [hide private]
int | max_depth the maximum depth of the keys that have ever been added to the dictionary.
int | max_depth_items the number of items of maximum depth

Properties | [hide private]
| __store
Inherited from `object`: `__class__`

Method Details | [hide private]

### __init__(self, *args, **kwargs) (Constructor) | source code
x.__init__(...) initializes x; see help(type(x)) for signature Overrides: object.__init__ (inherited documentation)

### __getitem__(self, key) (Indexing operator) | source code
Overrides: _abcoll.Mapping.__getitem__

### __setitem__(self, key, value) (Index assignment operator) | source code
Overrides: _abcoll.MutableMapping.__setitem__

### __delitem__(self, key) (Index deletion operator) | source code
Overrides: _abcoll.MutableMapping.__delitem__

### __iter__(self) | source code
Overrides: _abcoll.Iterable.__iter__

### __len__(self) (Length operator) | source code
Overrides: _abcoll.Sized.__len__

### get_deepest_match(self, name) | source code
Find the deepest match to name in the dictionary. The deepest match is the longest name in the dictionary which is a superdomain of name. Parameters: `name` (dns.name.Name object) - the name Returns: (key, value) tuple