API Reference for Enthought Tool Suite 3.2.0

A preferences node that adds the notion of preferences scopes.

Path names passed to the node can either contain scope information or can simply be a preference path. In the latter case, the operation takes place in the first scope in the node's list of scopes.

The syntax of a fully qualified path name is:

scope_name/some/arbitrary/scope/context/path.to.a.preference

The scope is up to the first '/'. The scope context (if any) is from the first '/' to the last '/', and the actual preference path is everything after the last '/'.

e.g. A preference path might look like this:

'project/My Project/my.plugin.id/acme.ui.bgcolor'

The scope is 'project'. The scope context is 'My Project/my.plugin.id' The preference path is 'acme.ui.bgcolor'

There is one drawback to this scheme. If you want to access a scope node itself via the 'clear', 'keys', 'node', 'node_exists' or 'node_names' methods then you have to append a trailing '/' to the path. Without that, the node would try to perform the operation in the first scope.

e.g. To get the names of the children of the 'application' scope, use:

scoped.node_names('application/')

If you did this:

scoped.node_names('application')

Then the node would get the first scope and try to find its child node called 'application'.

Of course you can just get the scope via:

scoped.get_scope('application')

and then call whatever methods you like on it!

Inherits from

Attributes

Inherited from base classes

Method summary

Inherited from base classes

Methods

© Copyright 2002-2009 Enthought, Inc.