Class::Autouse

Run-time load a class the first time you call a method in it.
Download

Class::Autouse Ranking & Summary

Advertisement

  • Rating:
  • License:
  • Perl Artistic License
  • Price:
  • FREE
  • Publisher Name:
  • Adam Kennedy
  • Publisher web site:
  • http://search.cpan.org/~adamk/

Class::Autouse Tags


Class::Autouse Description

Run-time load a class the first time you call a method in it. Class::Autouse is a Perl run-time to load a class the first time you call a method in it.SYNOPSIS # Debugging (if you go that way) must be set before the first use BEGIN { $Class::Autouse::DEBUG = 1; } # Load a class on method call use Class::Autouse; Class::Autouse->autouse( 'CGI' ); print CGI->b('Wow!'); # Use as a pragma use Class::Autouse qw{CGI}; # Turn on developer mode use Class::Autouse qw{:devel}; # Turn on the Super Loader use Class::Autouse qw{:superloader}; # Disable module-existance check, and thus one additional 'stat' # per module, at autouse-time if loading modules off a remote # network drive such as NFS or SMB. use Class::Autouse qw{:nostat};Class::Autouse allows you to specify a class the will only load when a method of that class is called. For large classes that might not be used during the running of a program, such as Date::Manip, this can save you large amounts of memory, and decrease the script load time a great deal. Requirements: · Perl


Class::Autouse Related Software