Perl::Critic::ConfigErrors - An exception object collecting a set of problems found by L<Perl::Critic::Config>.



NAME

Perl::Critic::ConfigErrors - An exception object collecting a set of problems found by the Perl::Critic::Config manpage.


DESCRIPTION

A set of configuration settings can have multiple problems. This is an object for collecting all the problems found so that the user can see them in one run. Stringification is overridden to allow this object to show all the messages when printed as the result of an eval.


METHODS

add_message( $message )
Accumulate the parameter with rest of the messages.

add_bad_option_message( $option_name, $value, $source, $suffix )
Accumulate a standardized message for a bad option. $option_name should have a leading minus (``-'') if the option was specified on a command line. $value is the input that was found wanting. $source should be the origination point of the $value, most likely the name of a .perlcriticrc. $suffix is the non-standard part of the message, describing the fault(s) of the $value.

messages()
Returns a reference to an array of the collected messages.

to_string()
Returns a string representation of this object, suitable for printing as an error message.


AUTHOR

Elliot Shank <perl@galumph.com>


COPYRIGHT

Copyright (c) 2007 Elliot Shank. All rights reserved.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. The full text of this license can be found in the LICENSE file included with this module.

 Perl::Critic::ConfigErrors - An exception object collecting a set of problems found by L<Perl::Critic::Config>.