users@jaxb.java.net

Re: binding docbook 5.0 to Java

From: castef <scasadei_at_yahoo.com>
Date: Wed, 3 Feb 2010 08:56:22 -0800 (PST)

I am somewhat reluctant to modify the schema since I am a novice.
On the other hand, the relax NG version, docbook.rng, was correctly parsed
by xjc.
parsing a schema...
compiling a schema...
But, I got lots of errors of the type:
[ERROR] Invalid class name "db.bridgehead.renderas.enumeration".
Either XJC has failed to derive a class name from XML name, or invalid name
is given.
Use <jaxb:class> customization to override a name.

These errors show up if and only if the string "enumeration" appears in the
name.
I tried to replace "enumeration" with "jenumeration" but that did not solve
the problem.
I am quite puzzled by this, even more so that the reserved keyword "class"
did not trigger an error (e.g., <define name="db.biblio.class.attribute">
was ok).

-SC


Wolfgang Laun-2 wrote:
>
> The duplications of the attributes "role" and "type" appear to be errors
> in the XML schema, compare the documentation of the docbook elements
> where this happens. You could remove these two <xs:attribute> elements
> whenever they are sibling of <xs:attributeGroup
> ref="docbook:db.common.linking.attributes"/>
>
> -W
>
> On Wed, Feb 3, 2010 at 2:02 PM, castef <scasadei_at_yahoo.com> wrote:
>>
>>
>>
>> Hello,
>> has someone been able to bind the docbook 5.0 schemas (xls and rng) to
>> Java?
>> I have been getting similar errors similar to those gotten by Raul Selas:
>>
>> 1) xsd
>> The command:
>> xjc -p docbook docbook.xsd
>> yields a long list of errors, the first one being:
>> [ERROR] Property "Role" is already defined. Use <jaxb:property> to
>> resolve
>> this conflict.
>> line 7999 of file:/C:/Users/stefano/core/___docbookjava/jaxb/docbook.xsd
>>
>> 2) rng
>> The command:
>> xjc –relaxng -p docbook docbook.rng
>> also yields a long list of errors, the first one being:
>> [ERROR] Invalid class name "db.bridgehead.renderas.enumeration". Either
>> XJC
>> has failed to derive a class name from XML name, or invalid name is
>> given.
>> Use <jaxb:class> customization to override a name.
>>  line 1734 of
>> file:/C:/Users/stefano/core/___docbookjava/fusesource/library/template/lib/docbook50/rng/docbook.rng
>>
>> Stefano
>>
>
>

-- 
View this message in context: http://old.nabble.com/What-does-it-means--%22compiler-was-unable-to-honor-this-property-customization.-It-is-attached-to-a-wrong-place%2C-or-its-inconsistent-with-other-bindings.%22-tp10196793p27439662.html
Sent from the java.net - jaxb users mailing list archive at Nabble.com.