You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by piyush raj jain <pi...@cdacb.ernet.in> on 2000/10/18 19:29:22 UTC

how to set attribute value as param for method call

Hi all ..
getting problem with
digester.addCallParam(java.lang.String pattern,
                         int paramIndex,
                         java.lang.String attributeName)
even after giving the valid attribute name method call is getting  null
...

went to the code of CallParamRule.body(....)


  public void body(String bodyText) throws Exception {
 if (attributeName == null)
     this.bodyText = bodyText.trim();
 else
   this.bodyText = null;
    }

pl. correct me i f wrong
1>every time first CallParamRule.begin() will be called
then bodyText will be set to Attribute's value..
2>then CallParamRule.body(...)will be invoked and bodyText will be set
to null
in case of atrribute presence .it will overwrite the attribute's value.


that is why even if i want to set the attribute's value as parameter for
method but it is passing null..

thanx and regards
piyush