You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by Kyle Robinson <KR...@pangaeainc.com> on 2002/01/31 19:39:07 UTC

RE: Digester user question - How to use objects/parameters not in the body

Yes, that helps.  Thanks.  I'll try it and let ya know.

-----Original Message-----
From: Scott Sanders [mailto:ssanders@nextance.com] 
Sent: Thursday, January 31, 2002 10:26 AM
To: Jakarta Commons Developers List
Subject: RE: Digester user question - How to use objects/parameters not in
the body


To use any of the existing rules, your Connection would have to be on the
stack.

Use digester.push to do this before you call parse().  Note that this will
make your Connection object the top object on the stack.

Alternatively, just create your own rule class and then have it take your
Connection as a parameter to set into the object.

Does that help?

Let me know if you need more,
Scott Sanders

> -----Original Message-----
> From: Kyle Robinson [mailto:KRobinson@pangaeainc.com]
> Sent: Thursday, January 31, 2002 10:32 AM
> To: 'commons-dev@jakarta.apache.org'
> Subject: Digester user question - How to use 
> objects/parameters not in the body
> 
> 
> Hopefully a quick question.  Here's what I want to do:
>  
> 1. Take an XML file
> 2. Use the digester to run through it, create an object and
> set a bunch of properties. 3. Then call a method in that 
> object while passing in a Connection object.
>  
> How do I do this?  Is there a way to call a
> digester.addCallParam with a value that is not in the body of 
> the XML?  Do I have to push my Connection onto the stack to 
> use it?  If so, how do I do that??
>  
> Any help is appreciated, thanks.
>  
> __________________
> Kyle Robinson
> Systems Consultant
> Pangaea Systems Inc.
> (250) 360-0111         
>  
> 

--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>