Add registries, which can be used to keep track of unique objects
Review Request #7780 — Created Nov. 25, 2015 and submitted — Latest diff uploaded
Registries are wrappers around Python's
set
class that provides the
additional constraints:
1. All registered members must have a core set of attributes
(defined per registry).
2. The values for these attributes must be unique across all members.A guide on writing registries has been added to the documentation.
- Ran unit tests.
- Built and viewed the docs.
Diff Revision 2
This is not the most recent revision of the diff. The latest diff is revision 20. See what's changed.
orig
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
djblets/util/registry/__init__.py |
---|
djblets/util/registry/errors.py |
---|
djblets/util/registry/registry.py |
---|
djblets/util/registry/tests.py |
---|