![]() |
|< 1 2 3 >| | ![]() |
29 Einträge, 3 Seiten |
1
2
3
4
5
6
my $self = {};
print "\$self ist ein Objekt von $1\n" if ref $self && $self =~ /([^=]*)=/;
bless $self, "Foo::Bar";
print "\$self ist ein Objekt von $1\n" if ref $self && $self =~ /([^=]*)=/;
QuoteTo determine if a reference is a blessed object, you can write
Code: (dl )print "It's an object\n" if UNIVERSAL::isa($val, 'UNIVERSAL');
Quote[/quote]To determine if a reference is a blessed object, you can write
Code: (dl )print "It's an object\n" if UNIVERSAL::isa($val, 'UNIVERSAL');
print "It's an object\n" if UNIVERSAL::isa($val, 'UNIVERSAL');
![]() |
|< 1 2 3 >| | ![]() |
29 Einträge, 3 Seiten |