1Util::Semaphore(3)    User Contributed Perl Documentation   Util::Semaphore(3)
2
3
4

NAME

6       Log::Log4perl::Util::Semaphore - Easy to use semaphores
7

SYNOPSIS

9           use Log::Log4perl::Util::Semaphore;
10           my $sem = Log::Log4perl::Util::Semaphore->new( key => "abc" );
11
12           $sem->semlock();
13             # ... critical section
14           $sem->semunlock();
15
16           $sem->semset( uid  => (getpwnam("hugo"))[2],
17                         gid  => 102,
18                         mode => 0644
19                       );
20

DESCRIPTION

22       Log::Log4perl::Util::Semaphore provides the synchronisation mechanism
23       for the Synchronized.pm appender in Log4perl, but can be used
24       independently of Log4perl.
25
26       As a convenience, the "uid" field accepts user names as well, which it
27       translates into the corresponding uid by running "getpwnam".
28
30       Copyright 2002-2009 by Mike Schilli <m@perlmeister.com> and Kevin Goess
31       <cpan@goess.org>.
32
33       This library is free software; you can redistribute it and/or modify it
34       under the same terms as Perl itself.
35
36
37
38perl v5.12.2                      2010-08-31                Util::Semaphore(3)
Impressum