[XML-DEV Mailing List Archive Home]
[By Thread]
[By Date]
[Recent Entries]
[Reply To This Message]
Re: Extracting Schema from an element instance while parsing.
- From: Michael Glavassevich <mrglavas@ca.ibm.com>
- To: xml-dev@lists.xml.org
- Date: Tue, 14 Sep 2010 19:50:00 -0400

David <dlee@calldei.com> wrote on 09/14/2010 04:00:13 PM:
> Thanks.
> After posting this post I did run into PSVIProvider and tried it out.
> Voila ! It worked (probably better then my code !)
> I felt so dumb ....
>
> Except ... it only works while parsing XML not generating it.
> In my use case I need access to the data while generating an XML
> document (from a different source),
> so that I can extract the annotation information *before* generating a
> particular element (it will guide the decision on what to generate).
> But using PSVIProvider, I might be able to do the same thing in 2 passes
> ... not entirely sure yet, still looking.
> Thanks for the suggestion.
Not sure how you're making decisions on what to write, but if you need to know the element declaration before you write the element, you could always keep a ValidatorHandler on the side and push SAX events to it and then retrieve the PSVI.
> There still is a use case (which I dont need yet but I think is useful).
> That is, given a simplified XPath, find the XSD information - Without
> having an instance document.
>
>
>
> David A. Lee
> dlee@calldei.com
> http://www.xmlsh.org
Thanks.
Michael Glavassevich
XML Parser Development
IBM Toronto Lab
E-mail: mrglavas@ca.ibm.com
E-mail: mrglavas@apache.org

[Date Prev]
| [Thread Prev]
| [Thread Next]
| [Date Next]
--
[Date Index]
| [Thread Index]
|
PURCHASE STYLUS STUDIO ONLINE TODAY!
Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!
Download The World's Best XML IDE!
Accelerate XML development with our award-winning XML IDE - Download a free trial today!
Subscribe in XML format
RSS 2.0 |
 |
Atom 0.3 |
 |
|
Stylus Studio has published XML-DEV in RSS and ATOM formats,
enabling users to easily subcribe to the list from their preferred news reader application.
|
Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website.
they were not included by the author in the initial post. To view the content without the Sponsor Links please
click here.
|
|