Title: RE: DTD Reading Urgent

Glenn,

I haven't tried your example yet, but if your output is a cut and paste of what you do get, it shows what I mean:

   <!ELEMENT
   [startEntity "%ent"] e %ent;
   [endEntity "%ent"]
   [elementDecl]>

In this case the startEntity/endEntity pair encloses not just the entity reference but also the element name.

How it would be different would be, for example, that the startElement callback would return me a series of literals, so that in the following (slightly simpler) example:


<!ELEMENT %elementname; (%cmbit;)>

startElement(String ns, String name, String contentModel, Attributes atts)

would give me name="%elementname;" and contentModel="%cmbit;"

I believe in this case, getProperty(...string) would give me:
[startOfMarkupDecl]
 <!ELEMENT
 [startEntity "%elementname"]
 [startEntity "%cmbit"]
  %elementname; %cmbit;
 [endEntity "%cmbit"]
 [endEntity "%elementname"]
 [elementDecl]>

(I admit, the question is a little hazy because of the very specific things I want to do with this information and the fact that I haven't yet sat down and thoroughly worked through all the use cases).

Regards,

John

-----Original Message-----
From: Glenn Marcy [mailto:[EMAIL PROTECTED]]
Sent: 09 August 2001 18:09
To: [email protected]
Cc: [email protected]; '[EMAIL PROTECTED]'
Subject: RE: DTD Reading Urgent



>The only problem is the same as with the standard SAX callbacks - the
>start entity tends not to come at the start of the entity reference,
>but at the start of the declaration which contains it.

I guess I don't understand this comment since the examples that I was
providing show that you do get the startEntity where you are expecting.
You are correct that SAX has rules that throw some of these events
away because the SAX methods are defined to do so, but all the events
native in Xerces are unfiltered and available for your use.

>What I'm really looking for is a way to get the unresolved string sent
>in the parameters for each callback.

How is that different than being able to do getProperty(".../xml-string")
in any callback to get that unresolved string ?

Regards,
Glenn



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to