1 package Config::Any::General;
7 use base 'Config::Any::Base';
11 Config::Any::General - Load Config::General files
15 Loads Config::General files. Example:
18 <Component Controller::Foo>
20 bar [ arrayref-value ]
30 return an array of valid extensions (C<cnf>, C<conf>).
35 return qw( cnf conf );
40 Attempts to load C<$file> via Config::General.
47 my $args = shift || {};
49 $args->{ -ConfigFile } = $file;
51 require Config::General;
52 Config::General->VERSION( '2.47' );
54 $args->{ -ForceArray } = 1 unless exists $args->{ -ForceArray };
56 my $configfile = Config::General->new( %$args );
57 my $config = { $configfile->getall };
62 =head2 requires_all_of( )
64 Specifies that this module requires L<Config::General> in order to work.
68 sub requires_all_of { [ 'Config::General' ] }
72 Brian Cassidy E<lt>bricas@cpan.orgE<gt>
76 Joel Bernstein E<lt>rataxis@cpan.orgE<gt>
78 =head1 COPYRIGHT AND LICENSE
80 Copyright 2006-2010 by Brian Cassidy
82 Portions Copyright 2006 Portugal Telecom
84 This library is free software; you can redistribute it and/or modify
85 it under the same terms as Perl itself.
93 =item * L<Config::Any>
95 =item * L<Config::General>