[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: ANN: Regular Associations


Re:  ANN: Regular Associations
> On Sun, Jan 04, 2004 at 10:32:25AM +0400, David Tolpin wrote:
> > I am proposing to validate it against a very small schema.
> [...]
> > In the worst case, that is, with the current implementation, it takes 1 second
> > of processor time to determine the type of a 5 megabytes XML file that fails
> > to match three RNG pattern productions.
> 
> And if I give you a 20 gigabyte stream?
> *not* parsing is always faster than parsing...
> 

If you give me a 20 gigabyte stream and ask to determine its contents based on a 
pattern that requires parsing of the whole stream, then it will take as much time
as required to parse it.

However, you will either not want to determine the stream's type according to something
that is half the way to the end of the stream or will not want to use the automatic
mechanism at all. As I mentioned, for all cases listed in the original proposal, 
it is easy not to parse the document beyond the point where one has to parse it.
'any' pattern is easily recognized and can be used to stop parsing.

If I am asked for the document element's name or namespace, or a list of names, then
the current program can be enhanced to parse just the document element. I will do it.
It is trivial. I just can't choose between parsing one input buffer (1024 bytes) of the stream 
and analysing pattern's contents, or adding a predefined pattern to the configuration grammar.

David Tolpin

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
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.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.