You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@xerces.apache.org by "Murphy, James" <Ja...@excelergy.com> on 2001/11/02 21:08:11 UTC

RE: Schema error vs. Instance error?

Report - Apologies for the repost but I'm kinda in a bind here.
Jim

> -----Original Message-----
> From: Murphy, James [mailto:James.Murphy@excelergy.com]
> Sent: Monday, October 29, 2001 4:39 PM
> To: 'xerces-c-dev@xml.apache.org'
> Subject: Schema error vs. Instance error?
> 
> 
> Hi all,
>  
> I am parsing an instance with an associated schema using 
> DOMParser.  I am trying to differentiate between errors 
> parsing the schema and errors parsing the instance.  
> Currently I can't tell in the call to error().  This is all 
> so I know when I can reuse grammar in the parser.  Obviously 
> if I fail to parse the schema I don't want to reuse the grammar.
>  
> I was looking atTraverseSchema::reportSchemError but I'm not 
> sure how to hook into it.  It seems kinda deep.  I also can't 
> seem to hook the XMLScanner's Error reporter since the 
> DOMParser keeps it under wraps.
> 
> Any thoughts?
> 
> Jim
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-c-dev-help@xml.apache.org
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-c-dev-help@xml.apache.org


Re: Schema error vs. Instance error?

Posted by Khaled Noaman <kn...@ca.ibm.com>.
Hi Jim,

Currently, there isn't a way to differentiate between instance/schema
parsing errors. Are you interested in per error basis, or just to know
whether the parser has encountered any errors during parsing the schema.

Here are some suggestions:
1. Modify the parser to register an additional error handler that is used
by schema traversal to report errors.
2. Add a method to the parser to inquire whether any errors were
encountered during parsing a schema.

Comments/suggestions are welcome.

Khaled

"Murphy, James" wrote:

> Report - Apologies for the repost but I'm kinda in a bind here.
> Jim
>
> > -----Original Message-----
> > From: Murphy, James [mailto:James.Murphy@excelergy.com]
> > Sent: Monday, October 29, 2001 4:39 PM
> > To: 'xerces-c-dev@xml.apache.org'
> > Subject: Schema error vs. Instance error?
> >
> >
> > Hi all,
> >
> > I am parsing an instance with an associated schema using
> > DOMParser.  I am trying to differentiate between errors
> > parsing the schema and errors parsing the instance.
> > Currently I can't tell in the call to error().  This is all
> > so I know when I can reuse grammar in the parser.  Obviously
> > if I fail to parse the schema I don't want to reuse the grammar.
> >
> > I was looking atTraverseSchema::reportSchemError but I'm not
> > sure how to hook into it.  It seems kinda deep.  I also can't
> > seem to hook the XMLScanner's Error reporter since the
> > DOMParser keeps it under wraps.
> >
> > Any thoughts?
> >
> > Jim
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
> > For additional commands, e-mail: xerces-c-dev-help@xml.apache.org
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-c-dev-help@xml.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-c-dev-help@xml.apache.org