MojoX::Validator::Constraint::Time - Time constraint
$validator->field('time')->constraint(time => [split => ':']);
Checks whether a value is a valid time. Time is a string with a separator (: by default), that is splitted into hour, minute, second sequence and then validated.
:
hour, minute, second
is_valid
Validates the constraint.
MojoX::Validator, MojoX::Constraint
To install MojoX::Validator, copy and paste the appropriate command in to your terminal.
cpanm
cpanm MojoX::Validator
CPAN shell
perl -MCPAN -e shell install MojoX::Validator
For more information on module installation, please visit the detailed CPAN module installation guide.