NAME
    FML::Filter::Size - filter based on mail size.

SYNOPSIS
    use FML::Filter::Size; my $filter = new FML::Filter::Size $curproc; if
    (defined $filter) { $filter->set_class('incoming_article'); my $rules =
    $config->get_as_array_ref('article_size_filter_rules');

        if (defined $rules) {
            $filter->set_rules( $rules );
        }

        $filter->size_check($mesg);
    }

DESCRIPTION
    "FML::Filter::Size" is the collection of filter rules based on mail
    size.

METHODS
  new()
    constructor.

  set_rules( $rules )
    overwrite rules by specified @$rules ($rules is ARRAY_REF).

  set_class( $class )
    set class e.g. incoming_article, outgoing_article, ...

  size_check($msg)
    $msg is "Mail::Message" object.

    "Usage":

        use FML::Filter::Size;
        my $obj  = new FML::Filter::Size;
        my $msg  = $curproc->{'incoming_message'};

        $obj->size_check($msg);
        if ($obj->error()) {
           # do something for wrong formated message ...
        }

FILTER RULES
  check_header_size($msg)
    check the size of mail header. throw reason via croak() if the size
    exceeds the limit.

  check_body_size($msg)
    check the size of mail body. throw reason via croak() if the size
    exceeds the limit.

CHECK COMMAND SYNTAX
  check_command_limit($msg, $type)
    check the total number of command requests.

  check_line_length_limit($msg, $type)
    check the length limit of one command request.

CODING STYLE
    See "http://www.fml.org/software/FNF/" on fml coding style guide.

AUTHOR
    Ken'ichi Fukamachi

COPYRIGHT
    Copyright (C) 2003,2004,2005,2007,2008 Ken'ichi Fukamachi

    All rights reserved. This program is free software; you can redistribute
    it and/or modify it under the same terms as Perl itself.

HISTORY
    FML::Filter::Size first appeared in fml8 mailing list driver package.
    See "http://www.fml.org/" for more details.

