|Syntactic Confectionery Delight|
pass Array/Hash reference to a module method?by c (Hermit)
|on Jun 26, 2002 at 22:55 UTC ( #177576=perlquestion: print w/replies, xml )||Need Help??|
c has asked for the wisdom of the Perl Monks concerning the following question:
I'm back to adding features in a script that I've been hacking on for quite a while now that deals with net::snmp. The module has a few method that use the standard format of $object->method(-argument => $value);
Since a method can have quite a number of -argment options passed to it at once, is there a method of passing them to the object through an array or an array reference? or perhaps I should be asking about passing them through a hash/hash reference. It seems as though I've read this as being a possibility with other modules, but I don't believe its present in net::snmp. Is this something that is module-specific or a standard that I can work on?
I guess my hypothesis is...
Would equate to...
Is this just wishful thinking?
thanks very much on this one -c
Back to Seekers of Perl Wisdom