comparison README.txt @ 80:c852ff04c940

note formal syntax of section names
author Jeff Hammel <jhammel@mozilla.com>
date Sun, 12 Jun 2011 10:52:20 -0700
parents 0b2019d0af98
children
comparison
equal deleted inserted replaced
79:122e3eddcdeb 80:c852ff04c940
108 108
109 4. ``[foo:bar:app=%(object)s,value=1:%(here)s/objects.py:MyClass]``: 109 4. ``[foo:bar:app=%(object)s,value=1:%(here)s/objects.py:MyClass]``:
110 the same as 3. but override the values in the ``bar`` section with 110 the same as 3. but override the values in the ``bar`` section with
111 ``app=%(object)s`` and ``value=1`` 111 ``app=%(object)s`` and ``value=1``
112 112
113 * ``[name:path]`` 113 Section Name Syntax
114 * ``[name:decorator:path]`` 114 -------------------
115 * ``[name:decorator:overrides:path]`` 115
116 - *[name:resource]* : create an object named *name* , where resource
117 is either a section name or a *path* as described in `JSON Format`_ .
118 In the case where *resouce* is another section name, the options
119 will overide the options given in the *resource* section and a new
120 object named *name* will be created. In the case where *section* is
121 a path, an object will be created as given by the *path* with the
122 given options.
123 - *[name:decorator:resource]* : create an object named *name* where
124 the object given by *resource* is passed to *decorator*. Overrides
125 and loading is as described for *[name:reource]* . An anonymous
126 object is created of the whole section name for the wrapped
127 object. So this form results in two sections for the `JSON Format`_ .
128 *decorator* is a section in the same namespace as *name*.
129 - *[name:decorator:overrides:resource]* : similar to
130 *[name:decorator:resource]* , but apply *overides* to the
131 *decorator* section. *overrides* is a string of the format
132 ``foo,bar,fleem=5``.
116 133
117 ---- 134 ----
118 135
119 Jeff Hammel 136 Jeff Hammel
120 http://k0s.org/ 137 http://k0s.org/