I want to alter the %find in my constructor from a accessor method.
how do I add elements to the find hash? I thought:
am I going about this the wrong way?
thanks
Code:
package Excel::Tabbed;
use strict;
use Exporter();
our @ISA = qw(Exporter);
our @EXPORT = qw(connect);
our $VERSION = 1.00;
# ie new constructor
sub connect{
my $class = $_[0];
if (-e "$_[1]"){
my %find;
my $object = {
connect => $_[1],
prepare => '',
select => '',
where => \%find,
column => '',
records => '',
};
bless $object, $class;
return $object;
}
else{
die "file: $_[1] doesn't reside at path\n";
}
}
how do I add elements to the find hash? I thought:
Code:
....
my ($self,$args) = @_;
my $find = $self->{where};
${find}->{name} = 'test';
thanks