Al Newkirk > Validation-Class-7.86 > Validation::Class::Field

Download:
Validation-Class-7.86.tar.gz

Dependencies

Annotate this POD

Website

View/Report Bugs
Module Version: 7.86   Source  

NAME ^

Validation::Class::Field - Field Object for Validation::Class Classes

VERSION ^

version 7.86

SYNOPSIS ^

    package SomeClass;
    
    use Validation::Class;
    
    package main;
    
    my $class = SomeClass->new;
    
    ...
    
    my $field = $class->get_field('some_field_name');
    
    $field->apply_filters;
    
    $field->validate; # validate this only
    
    $field->errors->count; # field-level errors
    
    1;

DESCRIPTION ^

Validation::Class::Field is responsible for field data handling in Validation::Class derived classes, performs functions at the field-level only.

This class automatically creates attributes for all acceptable field directives as listed under "DIRECTIVES" in Validation::Class::Prototype.

ATTRIBUTES ^

errors

The errors attribute is a Validation::Class::Errors object.

METHODS ^

new

    my $self = Validation::Class::Field->new({
        name => 'some_field_name'
    });

AUTHOR ^

Al Newkirk <anewkirk@ana.io>

COPYRIGHT AND LICENSE ^

This software is copyright (c) 2011 by Al Newkirk.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.

syntax highlighting: