[Grok-dev] getting data from root in debug mode

Jan-Wijbrand Kolman janwijbrand at gmail.com
Thu Feb 5 02:56:49 EST 2009


On Thu, Feb 5, 2009 at 4:53 AM, lslatr <lslatr at gmail.com> wrote:
>
> I want to navigate the database from the debug prompt.  I see the "root" node
> defined but I can't figure out how to havigate down it.  Something like
>
>>>> root.project.myobject
>
> Any thoughts?

The root folder is a "container-like" object, supporting the IMapping
interface - the same that a normal python dicts implement. In other
words, you can get to subobjects that are contained in the
(root)folder like so:

  obj = root['project']['myobject']

regards,
jw


More information about the Grok-dev mailing list