You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by "Edelson, Justin" <Ju...@mtvi.com> on 2004/03/23 18:18:25 UTC

[digester] mixed content update

I'm trying to figure out the best way to digest some XML with mixed
content, i.e.

<a>
    <b>
        <c>beginning text <d attr="foo"/> ending text</c>
    </b>
</a>

Where it's important for "beginning text" and "ending text" to be
treated separately.

I looked through the mailing list archives and found a discussion from
early 2002 on this subject. It looks like the net result of that
discussion was that, in my example above, the content "beginning text
ending text" is made available by using a CallMethodRule.

Has there been any subsequent discussion? I got the sense that the
decision really was that mixed content wasn't "for" Digester in the
sense that Digester is targeted to loading configuration files that
"tend to be either all-attributes or all-body-content"
(http://nagoya.apache.org/eyebrowse/ReadMsg?listName=commons-dev@jakarta
.apache.org&msgId=72369).

I'll happily give up using Digester to accomplished by mixed-content
project and switch to JDOM (or even look at the Avalon Configuration
stuff someone mentioned), but I wanted to check with the list before
giving up.

Thanks,
Justin

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


RE: [digester] mixed content update

Posted by Scott Sanders <sa...@apache.org>.
Justin,

Digester is not set up to handle mixed content.  I would use something else,
or modify Digester to do what you want.

Scott (originator of the mixed content thread)

> -----Original Message-----
> From: Edelson, Justin [mailto:Justin.Edelson@mtvi.com]
> Sent: Tuesday, March 23, 2004 9:18 AM
> To: Jakarta Commons Developers List
> Subject: [digester] mixed content update
> 
> I'm trying to figure out the best way to digest some XML with mixed
> content, i.e.
> 
> <a>
>     <b>
>         <c>beginning text <d attr="foo"/> ending text</c>
>     </b>
> </a>
> 
> Where it's important for "beginning text" and "ending text" to be
> treated separately.
> 
> I looked through the mailing list archives and found a discussion from
> early 2002 on this subject. It looks like the net result of that
> discussion was that, in my example above, the content "beginning text
> ending text" is made available by using a CallMethodRule.
> 
> Has there been any subsequent discussion? I got the sense that the
> decision really was that mixed content wasn't "for" Digester in the
> sense that Digester is targeted to loading configuration files that
> "tend to be either all-attributes or all-body-content"
> (http://nagoya.apache.org/eyebrowse/ReadMsg?listName=commons-dev@jakarta
> .apache.org&msgId=72369).
> 
> I'll happily give up using Digester to accomplished by mixed-content
> project and switch to JDOM (or even look at the Avalon Configuration
> stuff someone mentioned), but I wanted to check with the list before
> giving up.
> 
> Thanks,
> Justin
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-dev-help@jakarta.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org