HTML::FormFu::Constraint::File::MaxSize - Maximum File Size Constraint


HTML-FormFu documentation Contained in the HTML-FormFu distribution.

Index


Code Index:

NAME

Top

HTML::FormFu::Constraint::File::MaxSize - Maximum File Size Constraint

DESCRIPTION

Top

Ensure that an uploaded file meets maximum size constraints.

Overrides localize_args in HTML::FormFu::Constraint, so that the value of maximum is passed as an argument to localize.

This constraint doesn't honour the not() value.

METHODS

Top

maximum

max

The maximum file size in bytes.

max is an alias for maximum.

SEE ALSO

Top

Is a sub-class of, and inherits methods from HTML::FormFu::Constraint::File::Size, HTML::FormFu::Constraint

HTML::FormFu

AUTHOR

Top

Carl Franks cfranks@cpan.org

LICENSE

Top

This library is free software, you can redistribute it and/or modify it under the same terms as Perl itself.


HTML-FormFu documentation Contained in the HTML-FormFu distribution.

package HTML::FormFu::Constraint::File::MaxSize;

use Moose;
extends 'HTML::FormFu::Constraint::File::Size';

sub _localize_args {
    my ($self) = @_;

    return $self->max;
}

__PACKAGE__->meta->make_immutable;

1;

__END__