Skip to Main Content

Java EE (Java Enterprise Edition) General Discussion

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

JAXB src-resolve error on xml:base attribute

843834Jul 12 2008 — edited Jul 12 2008
I'm trying to compile an xsd using JAXB 2.1.2. I have an element defined that has a reference attribute of xml:base (I do this for Xinclude). I get a src-resolve error when attemting to compile. Below is an example XSD that demonstrates my problem.
<?xml version="1.0" encoding="UTF-8"?>
<schema xmlns="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:foobar="foobar" targetNamespace="foobar" elementFormDefault="qualified" version="1.0" id="foobar.xsd"
xsi:schemaLocation="foobar foobar.xsd">
	<import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="http://www.w3.org/2005/08/xml.xsd"/>
	<element name="Foo" type="foobar:Bar"/>
	<complexType name="Bar">
		<attribute ref="xml:base"/>
	</complexType>
</schema>
This is the error I get:
[ERROR] src-resolve: Cannot resolve the name 'xml:base' to a(n) 'attribute declaration' component.
Why am I getting this error?
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Aug 9 2008
Added on Jul 12 2008
1 comment
290 views