"I cannot install this as a module on the system, I only have limited access to where I can put my files."
I would like to bring your attention to
non-priviledged installations in case you didn't
already know that you can install modules on your system. :)
(updated ... added paragraph)
Now then. As for exporting ... why do people think that exporting is easier to implement
then OO? If you stick with OO methods (that is, you instantiate a class and use it's methods)
then you never have to worry about cluttering namespace or getting the Export code correct.
Besides, these days you can cheat big time with modules like Class::MethodMaker that
"write the code for you." Observe:
my $dude = new Person;
$dude->name('Spicoli');
$dude->age(20);
print $dude->as_string, "\n";
package Person;
use Class::MethodMaker
new => 'new',
get_set => [qw(name age)],
;
sub as_string {
my $self = shift;
return $self->name . ' (' . $self->age . ')';
}
Much nicer. :)