Help for this page
# an object is simply a closure with a hash of closures sub make_object { ... $msg{$m}->(@_) : print "unknown message\n"; } }
# build an object my $object = make_object(); ... &$object("get-self")->("add-msg", "test", sub {print "test ok!\n"}); &$object("test"); # ==> display "test ok!"
www.com | www.net | www.org
No recent polls found