1Config::Model::models::UIstesrelCfo:n:tErliebmuetnetdC(o3Pn)efrilg:D:oMcoudmeeln:t:amtoidoenls::Itself::Element(3)
2
3
4

NAME

6       Config::Model::models::Itself::Element - Configuration class
7       Itself::Element
8

DESCRIPTION

10       Configuration classes used by Config::Model
11

Elements

13   type
14       specify the type of the configuration element.Leaf is used for plain
15       value.  Mandatory. Type enum. choice: 'node', 'warped_node', 'hash',
16       'list', 'leaf', 'check_list'.
17
18   value_type
19        Optional. Type enum. choice: 'boolean', 'enum', 'integer',
20       'reference', 'number', 'uniline', 'string', 'file', 'dir'.
21
22       Here are some explanations on the possible values:
23
24       'integer'
25           positive or negative integer
26
27       'uniline'
28           string with no embedded newline
29
30   class - Override implementation of element
31       Perl class name used to override the implementation of the
32       configuration element. This override Perl class must inherit a
33       Config::Model class that matches the element type, i.e.
34       Config::Model::Value, Config::Model::HashId or Config::Model::ListId.
35       Use with care.  Optional. Type uniline.
36
37   morph
38       When set, a recurse copy of the value from the old object to the new
39       object is attemped. Old values are dropped when  a copy is not possible
40       (usually because of mismatching types)  Optional. Type boolean.
41
42   refer_to
43       points to an array or hash element in the configuration tree using grab
44       syntax. The available choice of this reference value (or check list)is
45       made from the available keys of the pointed hash element or the values
46       of the pointed array element.  Optional. Type uniline.
47
48   computed_refer_to
49       points to an array or hash element in the configuration tree using a
50       path computed with value from several other elements in the
51       configuration tree. The available choice of this reference value (or
52       check list) is made from the available keys of the pointed hash element
53       or the values of the pointed array element. The keys of several hashes
54       (or lists) can be combined by using the '+' operator in the formula.
55       For instance, '! host:$a lan + ! host:foobar lan'. See
56       Config::Model::IdElementReference for more details.  Optional. Type
57       warped_node.
58
59   replace_follow
60       Path specifying a hash of value element in the configuration tree. The
61       hash if used in a way similar to the replace parameter. In this case,
62       the replacement is not coded in the model but specified by the
63       configuration.  Optional. Type uniline.
64
65   compute
66       compute the default value according to a formula and value from other
67       elements in the configuration tree.  Optional. Type warped_node.
68
69   migrate_from
70       Specify an upgrade path from an old value and compute the value to
71       store in the new element.  Optional. Type warped_node.
72
73   write_as
74       Specify how to write a boolean value. Example 'no' 'yes'.  Optional.
75       Type list of uniline.
76
77   migrate_values_from
78       Specifies that the values of the hash or list are copied from another
79       hash or list in the configuration tree once configuration data are
80       loaded.  Optional. Type uniline.
81
82   migrate_keys_from
83       Specifies that the keys of the hash are copied from another hash in the
84       configuration tree only when the hash is created.  Optional. Type
85       uniline.
86
87   write_empty_value
88       By default, hash entries without data are not saved in configuration
89       files. Set this parameter to 1 if a key must be saved in the
90       configuration file even if the hash contains no value for that key.
91       Optional. Type boolean.
92
93       upstream_default value :
94           0
95
96   mandatory
97        Optional. Type boolean.
98
99   config_class_name
100        Optional. Type reference.
101
102   choice
103       Specify the possible values of an enum. This can also be used in a
104       reference element so the possible enum value will be the combination of
105       the specified choice and the referred to values.  Optional. Type list
106       of uniline.
107
108   min
109       minimum value.  Optional. Type number.
110
111   max
112       maximum value.  Optional. Type number.
113
114   min_index
115       minimum number of keys.  Optional. Type integer.
116
117   max_index
118       maximum number of keys.  Optional. Type integer.
119
120   default
121       Specify default value. This default value is written in the
122       configuration data.  Optional. Type string.
123
124   upstream_default
125       Another way to specify a default value. But this default value is
126       considered as "built_in" the application and is not written in the
127       configuration data (unless modified)  Optional. Type string.
128
129   convert
130       Convert value or index to uppercase (uc) or lowercase (lc).  Optional.
131       Type enum.
132
133   match
134       Perl regular expression to assert the validity of the value. To check
135       the whole value, use "^" and "$". For instance "^foo|bar$" allows "foo"
136       or "bar" but not "foobar". To be case insentive, use the "(?i)"
137       extended pattern. For instance, the regexp "^(?i)foo|bar$" also allows
138       the values "Foo" and "Bar".  Optional. Type uniline.
139
140   assert
141       Raise an error if the test code snippet does returns false. Note this
142       snippet is also run on undefined value, which may not be what you want.
143       Optional. Type hash of node of class Itself::CommonElement::Assert .
144
145   warn_if
146       Warn user if the code snippet returns true.  Optional. Type hash of
147       node of class Itself::CommonElement::Assert .
148
149   warn_unless
150       Warn user if the code snippet returns false.  Optional. Type hash of
151       node of class Itself::CommonElement::Assert .
152
153   warn_if_match
154       Warn user if a defined value matches the regular expression.  Optional.
155       Type hash of node of class Itself::CommonElement::WarnIfMatch .
156
157   warn_unless_match
158       Warn user if defined value does not match the regular expression.
159       Optional. Type hash of node of class Itself::CommonElement::WarnIfMatch
160       .
161
162   warn
163       Unconditionally issue a warning with this string when this parameter is
164       used. This should be used mostly with "accept"  Optional. Type string.
165
166   grammar
167       Feed this grammar to Parse::RecDescent to perform validation.
168       Optional. Type string.
169
170   default_list
171       Specify items checked by default.  Optional. Type check_list.
172
173   upstream_default_list
174       Specify items checked by default in the application.  Optional. Type
175       check_list.
176
177   allow_keys_from
178       this hash allows keys from the keys of the hash pointed by the path
179       string.  Optional. Type uniline.
180
181   allow_keys_matching
182       Keys must match the specified regular expression.  Optional. Type
183       uniline.
184
185   follow_keys_from
186       this hash contains the same keys as the hash pointed by the path
187       string.  Optional. Type uniline.
188
189   warn_if_key_match
190       Warn user if a key is created matching this regular expression.
191       Optional. Type uniline.
192
193   warn_unless_key_match
194       Warn user if a key is created not matching this regular expression.
195       Optional. Type uniline.
196
197   ordered
198       keep track of the order of the elements of this hash.  Optional. Type
199       boolean.
200
201   default_keys
202       default keys hashes.  Optional. Type list of string.
203
204   auto_create_keys
205       always create a set of keys specified in this list.  Optional. Type
206       list of string.
207
208   allow_keys
209       specify a set of allowed keys.  Optional. Type list of string.
210
211   auto_create_ids
212       always create the number of id specified in this integer.  Optional.
213       Type string.
214
215   default_with_init
216       specify a set of keys to create and initialization on some elements .
217       E.g. ' foo => "X=Av Y=Bv", bar => "Y=Av Z=Cz"'  Optional. Type hash of
218       string.
219
220   max_nb
221        Optional. Type integer.
222
223   replace
224       Used for enum to substitute one value with another. This parameter must
225       be used to enable user to upgrade a configuration with obsolete values.
226       The old value is the key of the hash, the new one is the value of the
227       hash.  Optional. Type hash of string.
228
229   duplicates
230       Specify the policy regarding duplicated values stored in the list or as
231       hash values (valid only when cargo type is "leaf"). The policy can be
232       "allow" (default), "suppress", "warn" (which offers the possibility to
233       apply a fix), "forbid".  Optional. Type enum. choice: 'allow',
234       'suppress', 'warn', 'forbid'.
235
236       upstream_default value :
237           allow
238
239   help
240       Specify help string specific to possible values. E.g for "light" value,
241       you could write " red => 'stop', green => 'walk'  Optional. Type hash
242       of string.
243
244   status
245        Optional. Type enum. choice: 'obsolete', 'deprecated', 'standard'.
246
247       upstream_default value :
248           standard
249
250   level
251       Used to highlight important parameter or to hide others. Hidden
252       parameter are mostly used to hide features that are unavailable at
253       start time. They can be made available later using warp mechanism.
254       Optional. Type enum. choice: 'important', 'normal', 'hidden'.
255
256       upstream_default value :
257           normal
258
259   summary
260       enter short information regarding this element.  Optional. Type
261       uniline.
262
263   description
264       enter detailed help information regarding this element.  Optional. Type
265       string.
266
267   warp
268       change the properties (i.e. default value or its value_type)
269       dynamically according to the value of another Value object located
270       elsewhere in the configuration tree.  Optional. Type warped_node of
271       class Itself::WarpValue .
272
273   index_type
274       Specify the type of allowed index for the hash. "String" means no
275       restriction.  Optional. Type enum.
276
277   cargo
278       Specify the properties of the configuration element configuration in
279       this hash or list.  Optional. Type warped_node.
280

SEE ALSO

282       ·   cme
283
284       ·   Config::Model::models::Itself::CommonElement::Assert
285
286       ·   Config::Model::models::Itself::CommonElement::WarnIfMatch
287
288       ·   Config::Model::models::Itself::WarpValue
289
290
291
292perl v5.28.0                      2018C-o0n8f-i0g7::Model::models::Itself::Element(3)
Impressum