pycocoa.dicts.FrozenDict

Package pycocoa :: Module dicts :: Class FrozenDict |
[frames] | no frames]

# Class FrozenDict

              object --+
                       |
    internals._Objectype --+
                           |
            baseTypes._Type0 --+
                               |
                 _FrozenDictBase --+
                                   |
                                  FrozenDict

Known Subclasses:
  - Dict

Python immutable `dict` Type, wrapping an (immutable) ObjC `NSDictionary`.

See Also: <https://code.ActiveState.com/recipes/414283-frozen-dictionaries/>

Instance Methods
__init__(self, *ns_dict, **kwds) New immutable FrozenDict, like `dict.__init__`. |
__contains__(self, key) |
__eq__(self, other) |
__getitem__(self, key) |
__len__(self) Return the length, like `dict.__len__`. |
__ne__(self, other) |
copy(self) Make a shallow copy. |
get(self, key, default=None) Return the value for the given key, like `dict.get`. |
items(self) Yield the key, value pairs, like `dict.items`. |
keys(self) Yield the keys, like `dict.keys`. |
__iter__(self) Yield the keys, like `dict.keys`. |
values(self) Yield the values, like `dict.values`. |
Inherited from `_FrozenDictBase`: `__call__`, `__delitem__`, `__setitem__`, `clear`, `pop`, `popitem`, `setdefault`, `update` Inherited from `baseTypes._Type0`: `__repr__`, `__str__`, `type2strepr` Inherited from `object`: `__delattr__`, `__format__`, `__getattribute__`, `__hash__`, `__new__`, `__reduce__`, `__reduce_ex__`, `__setattr__`, `__sizeof__`, `__subclasshook__`

Properties
Inherited from `baseTypes._Type0`: `NS`, `NSDelegate` Inherited from `internals._Objectype`: `typename` Inherited from `object`: `__class__`

Method Details

### __init__(self, *ns_dict, **kwds) (Constructor) |
New immutable FrozenDict, like `dict.__init__`. Overrides: object.__init__

### copy(self) |
Make a shallow copy. Returns: The copy (FrozenDict).