Validator::Lazy::Role::Composer
Version 0.01
use Validator::Lazy; my $v = Validator::Lazy->new( $config ); my $ok = $v->check( $hashref_of_your_data_to_chech ); # true / false OR my ( $ok, $data ) = $v->check( $hashref_of_your_data_to_chech ); # true / false say Dumper $v->errors; # [ { code => any_error_code, field => field_with_error, data => { variable data for more accurate error definition } } ] say Dumper $v->warnings; # [ { code => any_warn_code, field => field_with_warn, data => { variable data for more accurate warn definition } } ] say Dumper $v->data; # Fixed data. For example trimmed strings, corrected char case, etc...
Provides "Composer" role for Validator::Lazy, part of Validator::Lazy package.
Contains $validator->get_field_roles, that performs compillation of configuration of validator.
get_field_roles
$validator->get_field_roles( $field, @skip_classes );
After installing, you can find documentation for this module with the perldoc command. perldoc Validator::Lazy You can also look for information at: RT, CPAN's request tracker (report bugs here) http://rt.cpan.org/NoAuth/Bugs.html?Dist=Validator-Lazy AnnoCPAN, Annotated CPAN documentation http://annocpan.org/dist/Validator-Lazy CPAN Ratings http://cpanratings.perl.org/d/Validator-Lazy Search CPAN http://search.cpan.org/dist/Validator-Lazy/
ANTONC <antonc@cpan.org>
This program is free software; you can redistribute it and/or modify it under the terms of the the Artistic License (2.0). You may obtain a copy of the full license at: L<http://www.perlfoundation.org/artistic_license_2_0>
$validator->get_field_roles( $field, @skip_classes ); $field - field name for which we should find all classes to validate @skip_classes - classes which is already done and do not need to be affected
To install Validator::Lazy, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Validator::Lazy
CPAN shell
perl -MCPAN -e shell install Validator::Lazy
For more information on module installation, please visit the detailed CPAN module installation guide.