2 # This is a meta scheme defining the format of uci schemes.
7 #-------------------------------------------------------------------------------
8 # Central package definition
12 #-------------------------------------------------------------------------------
14 # Section definition (schema.@package)
17 option title 'Definition of uci package'
18 option package 'schema'
24 # Section title (schema.@package.title)
27 option title 'Title of the defined package'
28 option section 'schema.package'
29 option type 'variable'
30 option datatype 'string'
33 # Section description (schema.@package.description)
35 option name 'description'
36 option title 'Description of the defined package'
37 option section 'schema.package'
38 option type 'lazylist'
39 option datatype 'string'
43 #-------------------------------------------------------------------------------
44 # Central section definition
48 #-------------------------------------------------------------------------------
50 # Section definition (schema.@section)
53 option title 'Definition of uci section'
54 option package 'schema'
60 # Section name (schema.@section.name)
63 option title 'Name of the defined section'
64 option section 'schema.section'
65 option type 'variable'
66 option datatype 'string'
69 # Section package (schema.@section.package)
72 option title 'Parent package of the defined section'
73 option section 'schema.section'
74 option type 'variable'
75 option datatype 'string'
78 # Section title (schema.@section.title)
81 option title 'Title of the defined section'
82 option section 'schema.section'
83 option type 'variable'
84 option datatype 'string'
87 # Section description (schema.@section.description)
89 option name 'description'
90 option title 'Description of the defined section'
91 option section 'schema.section'
92 option type 'lazylist'
93 option datatype 'string'
96 # Section dependencies (schema.@section.depends)
99 option title 'List of dependencies within and between defined sections'
100 option section 'schema.section'
101 option type 'lazylist'
102 option datatype 'string'
103 option required false
105 # Section required flag (schema.@section.required)
107 option name 'required'
108 option title 'Specify whether at least one instance of this section type must be defined in config'
109 option section 'schema.section'
110 option type 'variable'
111 option datatype 'boolean'
112 option required false
114 # Section unique flag (schema.@section.unique)
117 option title 'Specify whether only one instance of this section type is allowed in config'
118 option section 'schema.section'
119 option type 'variable'
120 option datatype 'boolean'
121 option required false
123 # Section named flag (schema.@section.named)
126 option title 'Specify whether sections of this type must have a name set (are not anonymous)'
127 option section 'schema.section'
128 option type 'variable'
129 option datatype 'boolean'
130 option required false
132 # Section dynamic flag (schema.@section.dynamic)
134 option name 'dynamic'
135 option title 'Specify whether sections of this type may contain arbitary, not specified options'
136 option section 'schema.section'
137 option type 'variable'
138 option datatype 'boolean'
139 option required false
142 #-------------------------------------------------------------------------------
143 # Central variable definition
147 #-------------------------------------------------------------------------------
149 # Variable definition (schema.@variable)
151 option name 'variable'
152 option title 'Definition of uci variable'
153 option package 'schema'
154 option required false
159 # Variable name (schema.@variable.name)
162 option title 'Name of the defined variable'
163 option section 'schema.variable'
164 option type 'variable'
165 option datatype 'string'
168 # Variable section (schema.@variable.section)
170 option name 'section'
171 option title 'Parent section of the defined variable'
172 option section 'schema.variable'
173 option type 'variable'
174 option datatype 'string'
177 # Variable title (schema.@variable.title)
180 option title 'Title of the defined variable'
181 option section 'schema.variable'
182 option type 'variable'
183 option datatype 'string'
184 option required false
186 # Variable description (schema.@variable.description)
188 option name 'description'
189 option title 'Description of the defined variable'
190 option section 'schema.variable'
191 option type 'lazylist'
192 option datatype 'string'
193 option required false
195 # Variable dependencies (schema.@variable.depends)
197 option name 'depends'
198 option title 'List of dependencies between defined variables'
199 option section 'schema.variable'
200 option type 'lazylist'
201 option datatype 'string'
202 option required false
204 # Variable required flag (schema.@variable.required)
206 option name 'required'
207 option title 'Specify whether this variable must be set in config'
208 option section 'schema.variable'
209 option type 'variable'
210 option datatype 'boolean'
211 option required false
213 # Variable multiple values flag (schema.@variable.multival)
215 option name 'multival'
216 option title 'Specify whether this variable may contain multiple values separated by space'
217 option section 'schema.variable'
218 option type 'variable'
219 option datatype 'boolean'
220 option required false
222 # Variable type (schema.@variable.type)
225 option title 'Type of this variable'
226 option section 'schema.variable'
228 option datatype 'string'
229 option required false
231 # Plain variable type (schema.@variable.type=variable)
233 option value 'variable'
234 option title 'This is a plain variable'
235 option variable 'schema.variable.type'
237 # Enum variable type (schema.@variable.type=enum)
240 option title 'This is a enum variable'
241 option variable 'schema.variable.type'
243 # List variable type (schema.@variable.type=list)
246 option title 'This is a list variable'
247 option variable 'schema.variable.type'
249 # List-or-Option variable type (schema.@variable.type=lazylist)
251 option value 'lazylist'
252 option title 'This is a list or option variable'
253 option variable 'schema.variable.type'
255 # Reference variable type (schema.@variable.type=reference)
257 option value 'reference'
258 option title 'This is a reference (valueof) variable'
259 option variable 'schema.variable.type'
261 # Variable datatype (schema.@variable.datatype)
263 option name 'datatype'
264 option title 'Datatype of this variable'
265 option section 'schema.variable'
266 option type 'variable'
267 option datatype 'string'
268 option required false
270 # Variable default value (schema.@variable.default)
272 option name 'default'
273 option title 'Default value of this variable'
274 option section 'schema.variable'
275 option type 'variable'
276 option datatype 'string'
277 option required false
279 # Variable validators (schema.@variable.validator)
281 option name 'validator'
282 option title 'Datatype of this variable'
283 option section 'schema.variable'
284 option type 'lazylist'
285 option datatype 'string'
286 option required false
288 # Variable value references (schema.@variable.valueof)
290 option name 'valueof'
291 option title 'Reference to section or option to read values from'
292 option section 'schema.variable'
293 option type 'lazylist'
294 option datatype 'string'
295 option required false
298 #-------------------------------------------------------------------------------
299 # Central enum definition
303 #-------------------------------------------------------------------------------
305 # Enum definition (schema.@enum)
308 option title 'Definition of uci enum value'
309 option package 'schema'
310 option required false
315 # Enum value (schema.@enum.value)
318 option title 'Value of the defined enum value'
319 option section 'schema.enum'
320 option type 'variable'
321 option datatype 'string'
324 # Enum variable (schema.@enum.variable)
326 option name 'variable'
327 option title 'Parent variable of the defined enum value'
328 option section 'schema.enum'
329 option type 'variable'
330 option datatype 'string'
333 # Enum value title (schema.@enum.title)
336 option title 'Title of the defined enum value'
337 option section 'schema.enum'
338 option type 'variable'
339 option datatype 'string'
340 option required false
342 # Enum value description (schema.@enum.description)
344 option name 'description'
345 option title 'Description of the defined enum value'
346 option section 'schema.enum'
347 option type 'lazylist'
348 option datatype 'string'
349 option required false
351 # Enum value dependencies (schema.@enum.depends)
353 option name 'depends'
354 option title 'List of dependencies on defined variables'
355 option section 'schema.enum'
356 option type 'lazylist'
357 option datatype 'string'
358 option required false
360 # Enum value default flag (schema.@enum.default)
362 option name 'default'
363 option title 'Specify whether this value is the default value of the parent enum'
364 option section 'schema.enum'
365 option type 'variable'
366 option datatype 'boolean'
367 option required false