NAME

Module::Checkstyle::Util - Convenient functions for checks

SUBROUTINES

format_expected_err ($expected, $got)

Return the string "Expected '$expected' but got '$got'" but with $expected and $got reduced to the reftype if they are references.

make_problem ($severity, $message, $line, $file)

Creates a new Module::Checkstyle::Problem object. See Module::Checkstyle::Problem for more info.

as_true ($value)

Returns 1 if $value is either "y", "yes", "true" or "1" not regarding case. All other value returns 0.

as_numeric ($value)

Returns the numeric value given in $value if it is integer-numeric with an optional minus-sign. All other values returns 0.

as_regexp ($value)

Returns a regular expression object that will match what's given in $value. If it creation of the regexp-object was unsuccessfull it will return undefined.

SEE ALSO

Module::Checkstyle