Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(2)  |  Call(1)  |  Derive(0)  |  Import(1)
Per-thread dictionary.

PerThreadDict behaves like a normal dict, but changes to it are kept
track of on a per-thread basis.  So if thread A adds a key/value pair
to the dict, only thread A sees that item.  There are a few non-standard
methods (clear, isEmpty), too.

This is implementated by keeping a dictionary of dictionaries; one for
each thread. The implementation is not a complete dict wrapper; only
some methods are implemented. If more methods are needed, see UserDict(more...)

src/w/e/Webware-for-Python-1.1.1/MiddleKit/Run/ObjectStore.py   Webware-for-Python(Download)
    # will try to mix it in.
from PerThreadList import PerThreadList, NonThreadedList
from PerThreadDict import PerThreadDict, NonThreadedDict
 
 
            self._newObjects = PerThreadList()
            self._deletedObjects = PerThreadList()
            self._changedObjects = PerThreadDict()
        else:
            self._hasChanges = False