in reply to Multiple classes in modules
If the file name is MyTest.pm, just do use MyTest or BEGIN { require "MyTest.pm"; } (subbtle differences left to you to lookup). use doesn't care what packages are used inside the file. For example,
use Bah looks for Bah.pm, and
use Foo::Bar looks for Foo/Bar.pm,
even if they contain packages
Cow::Moo,
Cow::Eat and
Milkmaid.
perl looks for the modules in the the paths listed in @INC. See use lib for a method to edit @INC.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Multiple classes in modules
by johnnywang (Priest) on Oct 05, 2004 at 20:06 UTC | |
by ikegami (Patriarch) on Oct 05, 2004 at 20:16 UTC |