At 00:34 2016-11-23, Dave Crozier DaveC@Flexipol.co.uk wrote:
Gene, Am I missing something here or couldn't you pass a Parameter Object in which all your parameters become properties? This would allow you a limitless number of parameters and also be interface independent.
Yes, you are missing something.
What I wanted -- I have given up on it -- was to be able to check that the number of parameters passed was correct.
The case that I ran into trouble with is when too many parameters are passed. Suppose a procedure takes three parameters and four are passed. It would be nice to be able to detect this in the procedure, but instead an error is thrown. This happens before anything in the procedure is executed. Yes, you could put that detection in the caller, but then, why not just call correctly? Plus this does not work if the procedure is standalone which is what I wanted.
[snip]
Sincerely,
Gene Wirchenko