CGI-Builder-Auth
view release on metacpan or search on metacpan
lib/CGI/Builder/Auth/GroupAdmin.pm view on Meta::CPAN
if($group->delete('dougm')) {
print "He's gone from the group\n";
}
=item exists($groupname, [$username])
True if $groupname is found in the database
if($group->exists('web-heads')) {
die "oh no!";
}
if($group->exists($groupname, $username) {
#$username is a member of $groupname
}
=item list([$groupname])
Returns a list of group names, or users in a group if '$name' is present.
@groups = $group->list;
@users = $group->list('web-heads');
=item user()
Short cut for creating an CGI::Builder::Auth::UserAdmin object.
All applicable attributes are inherited, but can be
overridden.
$user = $group->user();
(See CGI::Builder::Auth::UserAdmin)
=item convert(@Attributes)
Convert a database.
#not yet
=item remove($groupname)
Remove group $groupname from the database
=item name($groupname)
Change the value of 'Name' attribute.
$group->name('bew-ediw-dlrow');
=item debug($boolean)
Turn debugging on or off
=item lock([$timeout])
=item unlock()
These methods give you control of the locking mechanism.
$group = new CGI::Builder::Auth::GroupAdmin (Locking => 0); #turn off auto-locking
$group->lock; #lock the object's database
$group->add($username,$passwd); #write while database is locked
$group->unlock; release the lock
=item db($dbname);
Select a different database.
$olddb = $group->db($newdb);
print "Now we're reading and writing '$newdb', done with '$olddb'n\";
=item flags([$flags])
Get or set read, write, create flags.
=item commit
Commit changes to disk (for Text files).
=back
=head1 SEE ALSO
CGI::Builder::Auth::UserAdmin(3)
=head1 AUTHOR
Doug MacEachern <dougm@osf.org>
Copyright (c) 1996, 1997 Doug MacEachern
This library is free software;
you can redistribute it and/or modify it under the same terms as Perl itself.
=cut
( run in 0.642 second using v1.01-cache-2.11-cpan-b16cb0d3907 )