Take me over?
NAME
Antispam::Toolkit::Role::UserChecker - A role for classes which check whether a user is a spammer
VERSION
version 0.01
SYNOPSIS
package MyUserChecker;
use Moose;
with 'Antispam::Toolkit::Role::UserChecker';
sub check_user { ... }
DESCRIPTION
This role specifies an interface for classes which check whether a specific user is a spammer.
REQUIRED METHODS
Classes which consume this method must provide one method:
$checker->check_user( ... )
This method implements the actual spam checking for a user. It must accept the following named parameters:
user
The user to be checked. This must be a non-empty string.
email
An email address associated with the user. This is optional.
ip
An ip address associated with the user. This is optional.
username
A username associated with the user. This is optional.
METHODS
This role provides an around modifier for the $checker->check_user()
method. The modifier does validation on all the parameters, so there's no need to implement this in the class itself.
The modifier also checks that at least one of the parameters has been provided, and croaks if this is not the case.
BUGS
See Antispam::Toolkit for bug reporting details.
AUTHOR
Dave Rolsky <autarch@urth.org>
COPYRIGHT AND LICENSE
This software is Copyright (c) 2010 by Dave Rolsky.
This is free software, licensed under:
The Artistic License 2.0