Data::Processor is pretty close to what you describe. Though I think you might find Types::Standard does what you want in a slightly different way.
use Types::Standard -types; my $state = StrMatch[qr/^[A-Z]{2}$/]; my $token = Str->where(sub { $database->check_valid_token($_) }); my $thing = Dict[token => $token, state => ArrayRef[$state]]; if ($thing->check($data)) { ...; }
In reply to Re: Data Object Verification Modules?
by tobyink
in thread Data Object Verification Modules?
by mwb613
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |