Are you using version 1.4.3 of Xerces or 1.4.4? I wrote an EntityResolver, which I use for resolving Schemas and it works with version 1.4.3, but not in 1.4.4.
In 1.4.3, the resolver is called for the 'schema-location' property and every 'include' element. In 1.4.4, the resolver only gets called for the 'schema-location' property, but gets ignored for 'include' elements. I would recommend trying version 1.4.3 if you're not using it. -----Original Message----- From: Taras Tielkes [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 12, 2001 9:48 AM To: '[EMAIL PROTECTED]' Subject: RE: Using EntityResolver for DTD file lookup Hi, It seems there's a bug in JAXP 1.1 When I set an EntityResolver on a XMLReader instance, and call parse() on the wrapping SAXParser instance, the resolver is never used. However, when I call parse() on the XMLReader instance, the resolver is invoked as expected. I'v entered a bug for JAXP in the javasoft bug db. Corey, I'll forward that bug report to you, since JAXP issues are a bit off-topic for this list. // tt > -----Original Message----- > From: Wineman, Corey J. [mailto:[EMAIL PROTECTED] > Sent: Tuesday, December 11, 2001 7:28 PM > To: [EMAIL PROTECTED] > Subject: RE: Using EntityResolver for DTD file lookup > > > Can anyone give an example implementation of EntityResolver? I have > tried to write my own, but I haven't got it to work. I always get an > error saying that DTD file could not be found. > > I would like my parser to be able to find DTD files without > them having > to necessarily be in the home directory or in the same > directory as the > XML files. > > -Corey > > -----Original Message----- > From: Wendi Sisson [mailto:[EMAIL PROTECTED] > Sent: Tuesday, December 11, 2001 1:13 PM > To: [EMAIL PROTECTED] > Subject: Re: Using EntityResolver for DTD file lookup > > > We use a DTD name with no path, URL, etc., and our > EntityResolver always > gets called. You should not need to use an URL. Maybe if the parser > finds the DTD in the default or current or home directory, it doesn't > call the EntityResolver? Wendi > > Raja Nagendra Kumar wrote: > > > > Hi! > > replace "marktcommentaar.dtd" with a URL such as > > xyz://abc.com/marktcommentaar.dtd. > > Regards, > > Nagendra > > ----- Original Message ----- > > From: "Taras Tielkes" <[EMAIL PROTECTED]> > > To: "Xerces-J-User (E-mail)" <[EMAIL PROTECTED]> > > Sent: Friday, November 23, 2001 9:58 PM > > Subject: Using EntityResolver for DTD file lookup > > > > > Hi, > > > > > > I'd like to use the EntityResolver interface to fetch DTD > files form > a > > > specific directory. > > > > > > My xml files look like: > > > > > > <?xml version="1.0" encoding="ISO-8859-1" ?> > > > <!DOCTYPE iris-research SYSTEM "marktcommentaar.dtd"> > > > <iris-research> > > > ... > > > > > > I'm registering my implementation with setEntityResolver(), but I > don't > > get > > > called. > > > > > > Any suggestions? > > > > > > Thanks, > > > > > > // tt > > > CONFIDENTIALITY NOTICE This message and any included attachments are from Cerner Corporation and are intended only for the addressee. The information contained in this message is confidential and may constitute inside or non-public information under international, federal, or state securities laws. Unauthorized forwarding, printing, copying, distribution, or use of such information is strictly prohibited and may be unlawful. If you are not the addressee, please promptly delete this message and notify the sender of the delivery error by e-mail or you may call Cerner's corporate offices in Kansas City, Missouri, U.S.A at (+1) (816)221-1024. ------------------------------------------- --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
