Forum OpenACS Development: Re: passing arguments, ad_proc definitions

Collapse
Posted by Torben Brosten on
I appreciate your input, Dave.

I'm using something like it for private procs of a package under development.

The functionality needs to be a part of ad_proc, because the public designated procs are planned to be repeatedly called via manually coded (typed) tcl files, and so should be as intuitive and convenient as possible.

Since ad_proc understandably doesn't appear to have the feature, it seems the most dynamic way (that doesn't add extra constraints) is to pass the named parameters as a list for these public designated cases:

qf_test \[list -arg1 value -arg2 value -arg3 value \]

or

qf_test $arg_list

Thank you, again,

Torben

Collapse
Posted by Dave Bauer on
What feature of ad_proc is missing here?

I forgot to mention in ad_proc youd specify like so

ad_proc a_proc { args }

since the arg list is necessary to pass to get_opts.

args works the same with ad_proc as with the standard tcl "proc" command.

Good luck!