These are known issues of the oAW XML formatter. Since oAW 4.2 it is implemented using the JAXP API due to IP issues. Unfortunately with JAXP you have troubles with Doctypes, Entities and some other. Basically the Fornax XML formatter is the oAW formatter before 4.2. It is based on DOM4J.

I strongly recommend to use this formatter. Because of those issues (which cannot be solved without implementing a totally own one) the oAW formatter will be deprecated.

~Karsten

On 01.10.2008 17:15 Uhr, amphoras wrote:
Hi,

I am using Sculptor to generate an XML file using an External Entity (see
http://www.xml.com/pub/a/98/08/xmlqna1.html#EXTENT).

This is what the Hibernate file should look like:

<!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD//EN"
"http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd"; [
   <!ENTITY UserInformation SYSTEM
"classpath://com/foo/hibernate/UserInformation.xml">
]>

<hibernate-mapping>
   <class...>
     ...
     &UserInformation;
     ...
   </class>
</hibernate-mapping>

I could not get this to generate correctly.  After much pain, I finally
figured out that there was nothing wrong with my template code.  The problem
is with the XML formatter.  The default
org.openarchitectureware.xpand2.output.XmlBeautifier eats both the ENTITY
declaration and the entity reference.  Then I tried the Fornax
org.fornax.utilities.formatter.xml.XmlFormatter.  I do like it better than
the oAW one because the XML looks much cleaner, and it leaves the ENTITY
declaration.  However, it replaces the entity reference with<!-- DUMMY -->!
So that still doesn't work.  I tried to not use a formatter at all, but the
XML that is generated has spaces in front of<?xml>, which is invalid.

Is there a setting or configuration that I can use to tell the formatter to
leave my external entity declaration and reference alone?  I know this is
unusual syntax, but it makes the most sense for our situation.

Thanks,
Polly




--
Karsten Thoms
Softwarearchitekt

Telefon: +49 (0) 231 / 98 60-202
Telefax: +49 (0) 231 / 98 60-211
Mobil  : +49 (0) 151 / 17396721

http://www.itemis.de
[EMAIL PROTECTED]

itemis AG
Am Brambusch 22
44536 Lünen

Rechtlicher Hinweis:
Amtsgericht Dortmund, HRB 20621

Vorstand: Wolfgang Neuhaus, Jens Wagener, Dr. Georg Pietrek

Aufsichtsrat: Dr. Burkhard Igel(Vors.), Stephan Grollmann, Michael Neuhaus

begin:vcard
fn:Karsten Thoms
n:Thoms;Karsten
org:itemis AG
adr:;;Am Brambusch 22;Luenen;;44536;Germany
email;internet:[EMAIL PROTECTED]
title:Softwarearchitekt
tel;work:+49 231 9860 202
tel;fax:+49 231 9860 211
tel;cell:+49 151 17396721
url:http://www.itemis.de
version:2.1
end:vcard

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Fornax-developer mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/fornax-developer

Reply via email to