Ezmlm - Object Methods for Ezmlm Mailing Lists
use Ezmlm; $list = new Ezmlm;
The rest is a bit complicated for a Synopsis, see the description.
Ezmlm is a Perl module that is designed to provide an object interface to the ezmlm mailing list manager software. See the ezmlm web page (http://www.ezmlm.org/) for a complete description of the software.
use Ezmlm; $list = new Ezmlm; $list = new Ezmlm('/home/user/lists/moolist');
$list->setlist('/home/user/lists/moolist');
$list->list; $list->list(STDERR);
@subscribers = $list->subscribers; print $list->subscribers;
$list->issub('nobody@on.web.za'); $list->issub(@addresses);
issub() returns 1 if all the addresses supplied are found as subscribers of the current mailing list, otherwise it returns undefined.
$list->sub('nobody@on.web.za'); $list->sub(@addresses);
sub() takes a LIST of addresses and subscribes them to the current mailing list.
$list->unsub('nobody@on.web.za'); $list->unsub(@addresses);
unsub() takes a LIST of addresses and unsubscribes them (if they exist) from the current mailing list.
$list->make(-dir=>'/home/user/list/moo', -qmail=>'/home/user/.qmail-moo', -name=>'user-moo', -host=>'on.web.za', -user=>'onwebza', -switches=>'mPz');
make() creates the list as defined and sets it to the current list. There are three variables which must be defined in order for this to occur; -dir, -qmail and -name.
make() returns the value of thislist() for success, undefined if there was a problem with the ezmlm-make system call and 0 if there was some other problem.
See the ezmlm-make(1) man page for more details
$whichlist = $list->thislist; print $list->thislist;
$list->getconfig;
getconfig() returns a string that contains the command line switches that would be necessary to re-create the current list. It does this by reading the DIR/config file if it exists. If it can't find this file it attempts to work things out for itself (with varying degrees of success). If both these methods fail, then getconfig() returns undefined.
$list->update('msPd');
update() can be used to rebuild the current mailing list with new command line options. These options can be supplied as a string argument to the procedure. Note that you do not need to supply the '-' or the 'e' command line switch.
All of the routines described above have return values. 0 or undefined are used to indicate that an error of some form has occoured, while anything >0 (including strings, etc) are used to indicate success.
For those who are interested, in those sub routines that have to make system calls to perform their function, an undefined value indicates that the system call failed, while 0 indicates some other error. Things that you would expect to return a string (such as thislist()) return undefined to indicate that they haven't a clue ... as opposed to the empty string which would mean that they know about nothing :)
Guy Antony Halse <guy-ezmlm@rucus.ru.ac.za>
None known yet. Please report bugs to the author.
ezmlm(5), ezmlm-make(2), ezmlm-sub(1), ezmlm-unsub(1), ezmlm-list(1), ezmlm-issub(1) http://rucus.ru.ac.za/~guy/ezmlm/ http://www.ezmlm.org/ http://www.qmail.org/
2 POD Errors
The following errors were encountered while parsing the POD:
'=item' outside of any '=over'
You forgot a '=back' before '=head2'
To install Mail::Ezmlm, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Mail::Ezmlm
CPAN shell
perl -MCPAN -e shell install Mail::Ezmlm
For more information on module installation, please visit the detailed CPAN module installation guide.