LWP::DebugSection: User Contributed Perl Documentation (3)Updated: 2004-04-06 |
LWP::DebugSection: User Contributed Perl Documentation (3)Updated: 2004-04-06 |
use LWP::Debug qw(+ -conns);
# Used internally in the library
LWP::Debug::trace('send()');
LWP::Debug::debug('url ok');
LWP::Debug::conns("read $n bytes: $data");
The following functions are available:
trace : trace function calls debug : print debug messages conns : show all data transfered over the connections
The LWP::Debug module provide a special import() method that allows you to pass the level() arguments with initial use statement. If a use argument start with '+' or '-' then it is passed to the level function, else the name is exported as usual. The following two statements are thus equivalent (if you ignore that the second pollutes your namespace):
use LWP::Debug qw(+);
use LWP::Debug qw(level); level('+');