You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-dev@xerces.apache.org by Maitreyee Pasad <pa...@gst.com> on 2000/08/18 20:06:32 UTC
No error with character data in an element with no PCDATA
Hi All,
I am using xerces 1_0_3
Consider an xml file
<!DOCTYPE E1 [
<!ELEMENT E1 (X|Y)>
<!ELEMENT Y (#PCDATA) >
<!ELEMENT X (#PCDATA) >
]>
<E1> asdasd asd
<X>test</X>
<Y>test1</Y>
</E1>
When I run this through sax.SAXCount2 it gives an error
bash-2.02$ java sax.SAX2Count -v 'E:\Users\pasad\Examples\XML\test1.xml'
[Error] test1.xml:10:7: The content of element type "E1" must match
"(X|Y)".
E:\Users\pasad\Examples\XML\test1.xml: 2093 ms (3 elems, 0 attrs, 5
spaces, 24 chars)
But this error goes unnoticed in my own code. I do have validation on.
Is there any other
feature that needs to be tuned on/off? Could there be something else
wrong?
Thanks.
Maitreyee
Re: No error with character data in an element with no PCDATA
Posted by Maitreyee Pasad <pa...@gst.com>.
I tried to change to xerces 1.1.2 but I had errors saying it could not open
files.
I think it has to do with later versions of xerces needing uri
instead of absolute path names. So I can't use later versions of xerces
until I have that problem resolved.
If anyone has sample code as to how to solve this problem it would be
appreciated.
Eric Ye wrote:
> That is a bug in Xerces 1.0.3, it has been fixed since Xerces 1.1.0, the
> latest version is 1.1.3, At the end of August we will have Xerces 1.1.4
> _____
>
> Eric Ye * IBM, JTC - Silicon Valley * ericye@locus.apache.org
>
> ----- Original Message -----
> From: "Maitreyee Pasad" <pa...@gst.com>
> To: <xe...@xml.apache.org>
> Sent: Friday, August 18, 2000 11:06 AM
> Subject: No error with character data in an element with no PCDATA
>
> >
> >
> > Hi All,
> >
> > I am using xerces 1_0_3
> >
> > Consider an xml file
> >
> >
> > <!DOCTYPE E1 [
> > <!ELEMENT E1 (X|Y)>
> > <!ELEMENT Y (#PCDATA) >
> > <!ELEMENT X (#PCDATA) >
> > ]>
> >
> > <E1> asdasd asd
> > <X>test</X>
> > <Y>test1</Y>
> > </E1>
> >
> > When I run this through sax.SAXCount2 it gives an error
> >
> > bash-2.02$ java sax.SAX2Count -v 'E:\Users\pasad\Examples\XML\test1.xml'
> > [Error] test1.xml:10:7: The content of element type "E1" must match
> > "(X|Y)".
> > E:\Users\pasad\Examples\XML\test1.xml: 2093 ms (3 elems, 0 attrs, 5
> > spaces, 24 chars)
> >
> > But this error goes unnoticed in my own code. I do have validation on.
> > Is there any other
> > feature that needs to be tuned on/off? Could there be something else
> > wrong?
> >
> >
> > Thanks.
> >
> > Maitreyee
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
> > For additional commands, e-mail: xerces-j-dev-help@xml.apache.org
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-j-dev-help@xml.apache.org
Re: No error with character data in an element with no PCDATA
Posted by Eric Ye <er...@locus.apache.org>.
That is a bug in Xerces 1.0.3, it has been fixed since Xerces 1.1.0, the
latest version is 1.1.3, At the end of August we will have Xerces 1.1.4
_____
Eric Ye * IBM, JTC - Silicon Valley * ericye@locus.apache.org
----- Original Message -----
From: "Maitreyee Pasad" <pa...@gst.com>
To: <xe...@xml.apache.org>
Sent: Friday, August 18, 2000 11:06 AM
Subject: No error with character data in an element with no PCDATA
>
>
> Hi All,
>
> I am using xerces 1_0_3
>
> Consider an xml file
>
>
> <!DOCTYPE E1 [
> <!ELEMENT E1 (X|Y)>
> <!ELEMENT Y (#PCDATA) >
> <!ELEMENT X (#PCDATA) >
> ]>
>
> <E1> asdasd asd
> <X>test</X>
> <Y>test1</Y>
> </E1>
>
> When I run this through sax.SAXCount2 it gives an error
>
> bash-2.02$ java sax.SAX2Count -v 'E:\Users\pasad\Examples\XML\test1.xml'
> [Error] test1.xml:10:7: The content of element type "E1" must match
> "(X|Y)".
> E:\Users\pasad\Examples\XML\test1.xml: 2093 ms (3 elems, 0 attrs, 5
> spaces, 24 chars)
>
> But this error goes unnoticed in my own code. I do have validation on.
> Is there any other
> feature that needs to be tuned on/off? Could there be something else
> wrong?
>
>
> Thanks.
>
> Maitreyee
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-j-dev-help@xml.apache.org
>
>
Re: No error with character data in an element with no PCDATA
Posted by Maitreyee Pasad <pa...@gst.com>.
Yes. My error handler prints errors to screen for all three call backs but
nothing gets printed on the screen.
Maitreyee
rsanford wrote:
> i asked the same question earlier this week...
>
> have you performed a setErrorHandler() with your own error handler?
>
> rjsjr
>
> > -----Original Message-----
> > From: Maitreyee Pasad [mailto:pasad@gst.com]
> > Sent: Friday, August 18, 2000 1:07 PM
> > To: xerces-j-dev@xml.apache.org
> > Subject: No error with character data in an element with no PCDATA
> >
> >
> >
> >
> > Hi All,
> >
> > I am using xerces 1_0_3
> >
> > Consider an xml file
> >
> >
> > <!DOCTYPE E1 [
> > <!ELEMENT E1 (X|Y)>
> > <!ELEMENT Y (#PCDATA) >
> > <!ELEMENT X (#PCDATA) >
> > ]>
> >
> > <E1> asdasd asd
> > <X>test</X>
> > <Y>test1</Y>
> > </E1>
> >
> > When I run this through sax.SAXCount2 it gives an error
> >
> > bash-2.02$ java sax.SAX2Count -v 'E:\Users\pasad\Examples\XML\test1.xml'
> > [Error] test1.xml:10:7: The content of element type "E1" must match
> > "(X|Y)".
> > E:\Users\pasad\Examples\XML\test1.xml: 2093 ms (3 elems, 0 attrs, 5
> > spaces, 24 chars)
> >
> > But this error goes unnoticed in my own code. I do have validation on.
> > Is there any other
> > feature that needs to be tuned on/off? Could there be something else
> > wrong?
> >
> >
> > Thanks.
> >
> > Maitreyee
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
> > For additional commands, e-mail: xerces-j-dev-help@xml.apache.org
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-j-dev-help@xml.apache.org
RE: No error with character data in an element with no PCDATA
Posted by rsanford <rs...@nolimitsystems.com>.
i asked the same question earlier this week...
have you performed a setErrorHandler() with your own error handler?
rjsjr
> -----Original Message-----
> From: Maitreyee Pasad [mailto:pasad@gst.com]
> Sent: Friday, August 18, 2000 1:07 PM
> To: xerces-j-dev@xml.apache.org
> Subject: No error with character data in an element with no PCDATA
>
>
>
>
> Hi All,
>
> I am using xerces 1_0_3
>
> Consider an xml file
>
>
> <!DOCTYPE E1 [
> <!ELEMENT E1 (X|Y)>
> <!ELEMENT Y (#PCDATA) >
> <!ELEMENT X (#PCDATA) >
> ]>
>
> <E1> asdasd asd
> <X>test</X>
> <Y>test1</Y>
> </E1>
>
> When I run this through sax.SAXCount2 it gives an error
>
> bash-2.02$ java sax.SAX2Count -v 'E:\Users\pasad\Examples\XML\test1.xml'
> [Error] test1.xml:10:7: The content of element type "E1" must match
> "(X|Y)".
> E:\Users\pasad\Examples\XML\test1.xml: 2093 ms (3 elems, 0 attrs, 5
> spaces, 24 chars)
>
> But this error goes unnoticed in my own code. I do have validation on.
> Is there any other
> feature that needs to be tuned on/off? Could there be something else
> wrong?
>
>
> Thanks.
>
> Maitreyee
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-j-dev-help@xml.apache.org
>