1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259
|
# PODNAME: Config::Model::models::Itself::ConfigReadWrite
# ABSTRACT: Configuration class Itself::ConfigReadWrite
=encoding utf8
=head1 NAME
Config::Model::models::Itself::ConfigReadWrite - Configuration class Itself::ConfigReadWrite
=head1 DESCRIPTION
Configuration classes used by L<Config::Model>
=head1 Elements
=head2 backend
specifies the backend to store permanently configuration data. I< Optional. Type enum. choice: 'cds_file', 'perl_file', 'custom'. >
Here are some explanations on the possible values:
=over
=item 'IniFile'
Ini file format. Beware that the structure of your model must match the limitations of the INI file format, i.e only a 2 levels hierarchy. Configuration filename is made with instance name
=item 'cds_file'
file with config data string. This is Config::Model own serialisation format, designed to be compact and readable. Configuration filename is made with instance name
=item 'custom'
deprecated
=item 'perl_file'
file with a perl data structure. Configuration filename is made with instance name
=back
=head2 config_dir
I< Optional. Type uniline. >
=head2 os_config_dir - configuration file directory for specific OS
Specify and alternate location of a configuration directory depending on the OS (as returned by C<$^O> or C<$Config{'osname'}>, see L<perlport/PLATFORMS>) Common values for C<$^O> are 'linux', 'MSWin32', 'darwin' I< Optional. Type hash of uniline. >
=head2 file - target configuration file name
specify the configuration file name. This parameter may not be applicable depending on your application. It may also be hardcoded in a custom backend. If not specified, the instance name is used as base name for your configuration file. The configuration file namecan be specified with &index() or &element function. See L<backend specifications|http://search.cpan.org/dist/Config-Model/lib/Config/Model/BackendMgr.pm#Backend_specification> and L<Config::Model::Role::ComputeFunction>. I< Optional. Type uniline. >
=head2 function
B<Deprecated> I< Optional. Type uniline. >
=head2 auto_create - Creates configuration files as needed
I< Optional. Type boolean. >
=over 4
=item upstream_default value :
0
=back
=head2 yaml_class
Specify the YAML class that is used to load and dump YAML files. Defaults to L<YAML::Tiny>. See L<yaml_class doc|Config::Model::Backend::Yaml/yaml_class> for details on why another YAML class can suit your configuration file needs. I< Optional. Type uniline. >
=over 4
=item upstream_default value :
YAML::Tiny
=back
=head2 file_mode - configuration file mode
specify the configuration file mode. C<file_mode> parameter can be used to set the mode of the written file. C<file_mode> value can be in any form supported by L<Path::Tiny/chmod>. I< Optional. Type uniline. >
=head2 default_layer - How to find default values in a global config file
Specifies where to find a global configuration file that specifies default values. For instance, this is used by OpenSSH to specify a global configuration file (C</etc/ssh/ssh_config>) that is overridden by user's file. I< Optional. Type node of class L<Itself::ConfigReadWrite::DefaultLayer|Config::Model::models::Itself::ConfigReadWrite::DefaultLayer> . >
=head2 class
I< Optional. Type uniline. >
=head2 store_class_in_hash
Specify element hash name that contains all INI classes. See L<Config::Model::Backend::IniFile/"Arbitrary class name"> I< Optional. Type uniline. >
=head2 section_map
Specify element name that contains one INI class. E.g. to store INI class [foo] in element Foo, specify { foo => "Foo" } I< Optional. Type hash of uniline. >
=head2 split_list_value
Regexp to split the value read from ini file. Usually "\s+" or "[,\s]" I< Optional. Type uniline. >
=head2 split_check_list_value
Regexp to split the value read from ini file. Usually "\s+" or "[,\s]" I< Optional. Type uniline. >
=head2 assign_char
Character used to assign value in INI file. Default is C<=>. See L<details|Config::Model::Backend::IniFile/"Handle key value files"> I< Optional. Type uniline. >
=over 4
=item upstream_default value :
#
=back
=head2 assign_with
String used write assignment in INI file. Default is "C< = >". See L<details|Config::Model::Backend::IniFile/"Handle key value files"> I< Optional. Type uniline. >
=over 4
=item upstream_default value :
#
=back
=head2 join_list_value
string to join list values before writing the entry in ini file. Usually " " or ", " I< Optional. Type uniline. >
=head2 join_check_list_value
string to join checked items names before writing the entry in the ini file. Usually " " or ", " I< Optional. Type uniline. >
=head2 write_boolean_as
Specify how to write a boolean value in config file. Suggested values are "no","yes". I< Optional. Type list of uniline. >
=head2 force_lc_section
force section to be lowercase. I< Optional. Type boolean. >
=over 4
=item upstream_default value :
0
=back
=head2 force_lc_key
force key names to be lowercase. I< Optional. Type boolean. >
=over 4
=item upstream_default value :
0
=back
=head2 force_lc_value
force values to be lowercase. I< Optional. Type boolean. >
=over 4
=item upstream_default value :
0
=back
=head2 full_dump
Also dump default values in the data structure. Useful if the dumped configuration data will be used by the application. (default is yes) I< Optional. Type boolean. >
=over 4
=item upstream_default value :
1
=back
=head2 comment_delimiter
list of characters that start a comment. When more that one character is used. the first one is used to write back comment. For instance, value "#;" indicate that a comments can start with "#" or ";" and that all comments are written back with "#". I< Optional. Type uniline. >
=over 4
=item upstream_default value :
#
=back
=head2 quote_value
Specify how to handle quoted values. By default, quoted values are left as is. With C<shell_style>, value are parsed and unquoted like in a shell. Values containing a space are written back with double quotes. I< Optional. Type enum. choice: 'shell_style'. >
=head2 auto_delete - Delete empty configuration file
Delete configuration files when no information is left in there. This may happen when data is removed by user. This is mostly useful when the configuration of an application is made of several files. I< Optional. Type boolean. >
=over 4
=item upstream_default value :
0
=back
=head1 SEE ALSO
=over
=item *
L<cme>
=item *
L<Config::Model::models::Itself::ConfigReadWrite::DefaultLayer>
=back
=cut
|