Config...gAccept(3pm)
โจ NAME โจ
okay bestie, meet Config::Model::models::Itself::ConfigAccept โ a Configuration class from the Itself::ConfigAccept era. she's the blueprint that tells Config::Model how to describe its own configuration elements, and she has OPINIONS ๐
๐ฆ DESCRIPTION ๐ฆ
These are the configuration classes used by Config::Model โ like, the meta layer. the thing that describes the things. very main character, very inception-core ๐
๐ Elements ๐
this is the whole roster, no skips, no cuts, we're going through ALL of them:
name_matchโ deprecated and optional, typeuniline.- upstream_default value:
.*
- upstream_default value:
accept_afterโ tells you where to insert the accepted element. heads up: this does not change the behavior at all, it just helps generate more consistent user interfaces. optional, typereference.typeโ specifies the type of the configuration element.Leafis what you use for a plain value. mandatory (yeah, you have to give her this one), typeenum. choices:'node','warped_node','hash','list','leaf','check_list'.value_typeโ optional, typeenum. choices:'boolean','enum','integer','reference','number','uniline','string','file','dir'.- here's the tea on a couple of those values:
'integer'โ a positive or negative integer ๐งฎ'uniline'โ a string with no embedded newline
classโ Override implementation of element. this is the Perl class name used to override how the configuration element is implemented. and listen: that override Perl class must inherit aConfig::Modelclass that matches the element type, i.e.Config::Model::Value,Config::Model::HashIdorConfig::Model::ListId. > Use with care. optional, typeuniline.morphโ when this is set, a recurse copy of the value from the old object to the new object is attempted. old values get dropped when a copy isn't possible (usually because the types don't match). optional, typeboolean.refer_toโ points to an array or hash element in the configuration tree using grab syntax. the available choice of this reference value (or check list) is made from the available keys of the pointed hash element, or the values of the pointed array element. optional, typeuniline.computed_refer_toโ same idea, but the path is computed using values from several other elements in the configuration tree. the available choice of this reference value (or check list) is made from the available keys of the pointed hash element or the values of the pointed array element. you can combine the keys of several hashes (or lists) by using the'+'operator in the formula โ for instance,'! host:$a lan + ! host:foobar lan'. seeConfig::Model::IdElementReferencefor more details. optional, typewarped_node.replace_followโ a path specifying a hash of value element in the configuration tree. the hash is used in a way similar to thereplaceparameter โ except the replacement isn't coded in the model, it's specified by the configuration. optional, typeuniline.computeโ computes the default value according to a formula and values from other elements in the configuration tree. optional, typewarped_node.migrate_fromโ specifies an upgrade path from an old value, and computes the value to store in the new element. optional, typewarped_node.write_asโ specifies how to write a boolean value. example:'no' 'yes'. optional, typelist of uniline.migrate_values_fromโ says that the values of the hash or list are copied from another hash or list in the configuration tree, once configuration data are loaded. optional, typeuniline.migrate_keys_fromโ says that the keys of the hash are copied from another hash in the configuration tree, but only when the hash is created. optional, typeuniline.write_empty_valueโ by default, hash entries without data are not saved in configuration files. set this parameter to1if a key must be saved in the configuration file even when the hash contains no value for that key. optional, typeboolean.- upstream_default value:
0
- upstream_default value:
mandatoryโ optional, typeboolean.config_class_nameโ optional, typereference.choiceโ specifies the possible values of an enum. you can also use this in a reference element, so the possible enum value becomes the combination of the specified choice and the referred-to values. optional, typelist of uniline.minโ minimum value. optional, typenumber.maxโ maximum value. optional, typenumber.min_indexโ minimum number of keys. optional, typeinteger.max_indexโ maximum number of keys. optional, typeinteger.updateโ update instructions to get a value from an external file when runningcme update. this requiresConfig::Model >= 2.157. optional, typenodeof classItself::CommonElement::Update.defaultโ specify a default value. this default value is written in the configuration data. optional, typestring.upstream_defaultโ another way to specify a default value. but this one is considered as "built_in" to the application, so it is not written in the configuration data (unless it's been modified). optional, typestring.convertโ convert value or index to uppercase (uc) or lowercase (lc). optional, typeenum.matchโ a Perl regular expression to assert the validity of the value. to check the whole value, use"^"and"$". for instance,"^foo|bar$"allows"foo"or"bar"but not"foobar". to be case insensitive, use the"(?i)"extended pattern โ for instance, the regexp"^(?i)foo|bar$"also allows the values"Foo"and"Bar". optional, typeuniline.assertโ raise an error if the test code snippet does return false. ngl, note that this snippet is also run on undefined values, which may not be what you want ๐ optional, typehash of nodeof classItself::CommonElement::Assert.warn_ifโ warn the user if the code snippet returns true. optional, typehash of nodeof classItself::CommonElement::Assert.warn_unlessโ warn the user if the code snippet returns false. optional, typehash of nodeof classItself::CommonElement::Assert.warn_if_matchโ warn the user if a defined value matches the regular expression. optional, typehash of nodeof classItself::CommonElement::WarnIfMatch.warn_unless_matchโ warn the user if a defined value does not match the regular expression. optional, typehash of nodeof classItself::CommonElement::WarnIfMatch.warnโ unconditionally issue a warning with this string when this parameter is used. this should be used mostly withaccept. optional, typestring.grammarโ feed this grammar toParse::RecDescentto perform validation. optional, typestring.default_listโ specify items checked by default. optional, typecheck_list.upstream_default_listโ specify items checked by default in the application. optional, typecheck_list.allow_keys_fromโ this hash allows keys from the keys of the hash pointed by the path string. optional, typeuniline.allow_keys_matchingโ keys must match the specified regular expression. optional, typeuniline.follow_keys_fromโ this hash contains the same keys as the hash pointed by the path string. optional, typeuniline.warn_if_key_matchโ warn the user if a key is created matching this regular expression. optional, typeuniline.warn_unless_key_matchโ warn the user if a key is created not matching this regular expression. optional, typeuniline.orderedโ keep track of the order of the elements of this hash. optional, typeboolean.default_keysโ default keys hashes. optional, typelist of string.auto_create_keysโ always create a set of keys specified in this list. optional, typelist of string.allow_keysโ specify a set of allowed keys. optional, typelist of string.auto_create_idsโ always create the number of ids specified in this integer. optional, typestring.default_with_initโ specify a set of keys and values to create and initialize some elements. e.g. initialize a hash of nodes with' foo => "X=Av Y=Bv", bar => "Y=Av Z=Cz"', or initialize a list of string with'0 => "foo", 1 => "bar"'. the values follow the syntax specified in"load string syntax"inConfig::Model::Loader. optional, typehash of string.max_nbโ optional, typeinteger.replaceโ used for enum to substitute one value with another. this parameter must be used to enable the user to upgrade a configuration with obsolete values. the old value is the key of the hash, the new one is the value of the hash. optional, typehash of string.duplicatesโ specifies the policy regarding duplicated values stored in the list or as hash values (valid only when cargo type is"leaf"). the policy can be"allow"(default),"suppress","warn"(which offers the possibility to apply a fix), or"forbid". optional, typeenum. choices:'allow','suppress','warn','forbid'.- upstream_default value:
allow
- upstream_default value:
helpโ specify a help string applicable to values. the keys are regexps matched to the beginning of the value. see the"help"parameter of"DESCRIPTION"inConfig::Model::Valuefor more possibilities. optional, typehash of string.statusโ optional, typeenum. choices:'obsolete','deprecated','standard'.- upstream_default value:
standard
- upstream_default value:
levelโ used to highlight an important parameter, or to hide others. hidden parameters are mostly used to hide features that are unavailable at start time โ they can be made available later using the warp mechanism. optional, typeenum. choices:'important','normal','hidden'.- upstream_default value:
normal
- upstream_default value:
summaryโ enter short information regarding this element. optional, typeuniline.descriptionโ enter detailed help information regarding this element. optional, typestring.warpโ change the properties (i.e. the default value or itsvalue_type) dynamically according to the value of anotherValueobject located elsewhere in the configuration tree. optional, typewarped_nodeof classItself::WarpValue.index_typeโ specify the type of allowed index for the hash."String"means no restriction. optional, typeenum.cargoโ specify the properties of the configuration element configuration in this hash or list. optional, typewarped_node.
๐ SEE ALSO ๐
go read these next, bestie, they're the whole friend group ๐ซถ
cmeConfig::Model::models::Itself::CommonElement::AssertConfig::Model::models::Itself::CommonElement::UpdateConfig::Model::models::Itself::CommonElement::WarnIfMatchConfig::Model::models::Itself::WarpValue
and that's the whole page, no cap โจ this one came from the User Contributed Perl Documentation collection, built for perl v5.40.1, dated 2026-03-10 โ she's iconic, she's detailed, she ate ๐
๐๐
๐ฆ where this page comes from
- ubuntu resolute: libconfig-model-itself-perl 2.027-1 ยท LGPL-2.1-only
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms