commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Simon Kitching <>
Subject Re: [digester] call-method-rule
Date Mon, 16 May 2005 13:08:15 GMT
Hi Markos,

On Mon, 2005-05-16 at 14:01 +0300, Markos Charatzas wrote:
> Is it possible to make a call to 2 different methods under the same pattern?

It depends. The *calls* will be made, but there is a design flaw in the
way that CallMethodParam interacts with CallMethodRule that makes things
tricky when using multiple "interlaced" CallMethodRules.

If one of the calls is made using no parameters, or just one parameter
being the body of the method, ie
  digester.addCallMethod(pattern, methodname)
  digester.addCallMethod(pattern, methodname, 0)
then I *think* the answer is yes (because no CallParamRule is being used
for that call).

If both calls have associated CallMethodRule instances, then I *think*
you'll find that the params get mixed up. The problem is that there is
just one "param stack", and that CallParamRule objects always work on
the set of params on top of the param stack, rather than knowing which
CallMethodRule they are supposed to be associated with.

Please note that I'm not absolutely certain on this; it's been a while
since I looked at CallMethodRule/CallParamRule.



To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message