diff options
Diffstat (limited to 'docs')
| -rw-r--r-- | docs/narr/hybrid.rst | 12 | ||||
| -rw-r--r-- | docs/narr/resources.rst | 2 |
2 files changed, 7 insertions, 7 deletions
diff --git a/docs/narr/hybrid.rst b/docs/narr/hybrid.rst index 24845ae93..97adaeafd 100644 --- a/docs/narr/hybrid.rst +++ b/docs/narr/hybrid.rst @@ -251,12 +251,12 @@ configuration statement: factory='mypackage.routes.root_factory') The ``factory`` above points at the function we've defined. It will return -an instance of the ``Traversable`` class as a root object whenever this route -is matched. Instances of the ``Resource`` class can be used for tree -traversal because they have a ``__getitem__`` method that does something -nominally useful. Since traversal uses ``__getitem__`` to walk the resources -of a resource tree, using traversal against the root resource implied by our -route statement is a reasonable thing to do. +an instance of the ``Resource`` class as a root object whenever this route is +matched. Instances of the ``Resource`` class can be used for tree traversal +because they have a ``__getitem__`` method that does something nominally +useful. Since traversal uses ``__getitem__`` to walk the resources of a +resource tree, using traversal against the root resource implied by our route +statement is a reasonable thing to do. .. note:: diff --git a/docs/narr/resources.rst b/docs/narr/resources.rst index ec5eaa4a7..fa8ccc549 100644 --- a/docs/narr/resources.rst +++ b/docs/narr/resources.rst @@ -88,7 +88,7 @@ Here's a sample resource tree, represented by a variable named ``root``: class Resource(dict): pass - root = Resource({'a': Resource({'b': Resource({'c': Resource()})})}) + root = Resource({'a':Resource({'b':Resource({'c':Resource()})})}) The resource tree we've created above is represented by a dictionary-like root object which has a single child named ``'a'``. ``'a'`` has a single child |
