Pedro Miguel Freire Custódio wrote:
> Hi,
>
> this is probably a stupid question. The question is that I want a
> particular class of objects to have several attributes, one of them a
> list (array), the problem is that I can't get it to work, it only
> stores the last value, and when I try to jo
hehe
thanks, i really tried a lot of stuff.. but i didn't figure out the @{}
operator... :)
It worked! ;)
Thanks,
Pedro
On 25 de jan de 2004, at 15:55, drieux wrote:
On Jan 25, 2004, at 7:47 AM, Pedro Miguel Freire Custódio wrote:
[..]
sub _init {
my $self = shift;
$self->{OBJECT} = ("xpto1",
On Jan 25, 2004, at 7:47 AM, Pedro Miguel Freire Custódio wrote:
[..]
sub _init {
my $self = shift;
$self->{OBJECT} = ("xpto1","xpto2"); ---> THE PROBLEM! It
only stores xpto2
if (@_) {
my %extra = @_;
@$self{keys %extra} = values %extra;
}
}
And when i try to use this method:
Hi,
this is probably a stupid question. The question is that I want a
particular class of objects to have several attributes, one of them a
list (array), the problem is that I can't get it to work, it only
stores the last value, and when I try to join another array it doesn't
work. If somebod