I'm getting an error message regarding the use of the <appinfo> element when
running xjc (from the xjc ant task) for some 3rd party schemas that I have.
I am using jwsdp-1.2 that I recently downloaded and installed on Win2k. The
error message is:
[xjc] [ERROR] unexpected character literal
[xjc] line 4 of geometryBasic0d1d.xsd
and I get this from multiple files in the same namespace with the same
issue. When examining each of these files, I found that there is an
<annoation> element block right after the initial <schema> element and
inside this <annoation> block is an <appinfo> element. If I simply comment
out the <appinfo> element, then the XJC task continues w/out errors.
Are there specific limitations with JAXB regarding the use of <appinfo>? Or
is this an illegal use of the <appinfo> element?
The start of the XML Schema document looks like this:
<?xml version="1.0" encoding="UTF-8"?>
<schema targetNamespace="
http://www.opengis.net/gml"
xmlns="
http://www.w3.org/2001/XMLSchema"
xmlns:sch="
http://www.ascc.net/xml/schematron"
xmlns:gml="
http://www.opengis.net/gml"
xmlns:xlink="
http://www.w3.org/1999/xlink"
elementFormDefault="qualified"
version="3.0.0">
<annotation>
<appinfo
source="urn:opengis:specification:gml:schemaxsd:geometryBasic0d1d:v3.0.0">ge
ometryBasic0d1d.xsd</appinfo>
<documentation>
Copyright (c) 2001-2002 OGC, All Rights Reserved.
</documentation>
</annotation>
<!-- ============================================================== -->
<include schemaLocation="measures.xsd">
<annotation>
<documentation>This includes not only measures.xsd, but also
units.xsd, gmlBase.xsd and basicTypes.xsd.</documentation>
</annotation>
</include>
............. <!-- the rest of the xml schema file follows --> .......
Enclosed is the complete 3rd party Xml Schema library that I'm using for
reference. I have actually found a variety of problems with trying to get
JAXB to compile this schema library (<appinfo>, use of abstract elements,
recursive behavior, etc.) so I'm not sure if this will be useful or not. I
was able to get successful validation via XmlSpy, but as many have
suggested, XmlSpy does not provide the best validation results.
Jerald Pratt
<<gml.zip>>
*****************************
Jerald Pratt
Northrop Grumman IT
jerpratt_at_northropgrumman.com
(858) 621-5479
*****************************
- application/octet-stream attachment: gml.zip