[Xml-compile] Schemas with mixed elements
Mark Overmeer
mark at overmeer.net
Mon Aug 25 20:35:57 BST 2008
* Drew Taylor (drew at drewtaylor.com) [080818 11:31]:
> What I'd like is an option to combine ATTRIBUTES and STRUCTURAL
> handling on the reader. Going back to my particular need, the xml
> looks like:
>
> <Segment>CDATA<Price>...</Price><Foo>...</Foo></Segment>
>
> The text will only occur once, and it will always be immediately after
> the parent tag. The new option I'm proposing would separate out the
> text into the '_' element, perhaps as an array to support multiple
> text chunks (overkill for me but may be useful to others). This is
> similar to the TEXTUAL option. In addition, the remaining non-text
> elements would be processed and transformed into a data structure as
> with the STRUCTURAL option.
The problem is purely in the user interface. Iff we are able to
define a nice, *general purpose* interface, it would be possible to
implement it. However, I haven't found such an interface smaller
than what XML::LibXML already offers...
> I would be willing to help implement this option, if you 1) don't
> think I'm crazy and 2) can point me in the right direction.
You are (probably) not crazy ;-)
--
MarkOv
------------------------------------------------------------------------
Mark Overmeer MSc MARKOV Solutions
Mark at Overmeer.net solutions at overmeer.net
http://Mark.Overmeer.net http://solutions.overmeer.net
More information about the Xml-compile
mailing list