NAME
Util::Thread::Logger - Thread-safe logging
VERSION
This documentation describes version 0.01
SYNOPSIS
use Util::Thread::Logger;
my $time = 'utc' if open my $handle, '>>', '/some/path';
my $logger = Util::Thread::Logger->new
(
log => $handle, ## path or I/O handle, *STDOUT if undef
time => $time, ## 'raw', 'utc', 'local', omit timestamp if undef
);
$logger->write( "timestamp in %s", $time );
METHODS
write
See printf().
SEE ALSO
threads, Thread::Semaphore
AUTHOR
Kan Liu
COPYRIGHT and LICENSE
Copyright (c) 2010. Kan Liu
This program is free software; you may redistribute it and/or modify it under the same terms as Perl itself.