in reply to Optionally include named arguments when constructing a new object

Hi,

boftx, thanks for the advice, I ended up basing my code on your "direct solution".

tobyink, thanks for pointing me towards the so-called "enterprise operator" ()x!! I found Aristotle's article about it (Secret Perl Operators: the boolean list squash operator, x!!). The article and the subsequent comments were very interesting.

jellisii2, thanks.

I had originally used Getopt::Long but my script is intended to be used with a Cacti 'script query' and it seems to me that it is better to use position dependent command line parameters in this case. Admittedly this is based on my fairly limited understanding of both Cacti and Perl. The notes on arg_prepend in The Complete XML File section in the Cacti script data query walkthrough show what I am attempting.

  • Comment on Re: Optionally include named arguments when constructing a new object