users@jaxb.java.net

Re: [HJ3] Cannot attach annotations to 'ref' elements

From: Aleksei Valikov <valikov_at_gmx.net>
Date: Thu, 25 Jan 2007 17:43:11 +0100

Hi.

> it may be a jaxb-2.x problem but it still does botther me!
>
> I have a schema like this:
> <xsd:complexType name="portsType">
> <xsd:sequence>
> <xsd:element ref="proci:problems" minOccurs="0" >
> <xsd:annotation>
> <xsd:appinfo>
> <hj:ignored/>
> </xsd:appinfo>
> </xsd:annotation>
> </xsd:element>
> </xsd:sequence>
> </xsd:complexType>
>
> And the XJC complains:
>
> [ERROR] XJC while parsing schema(s)
> file:/home/kana/work/hyperjaxb3-hibernate-sample-0.1/src/main/resources/larysi.xsd[54,26]:
>
> org.xml.sax.SAXParseException: The prefix "hj" for element
> "hj:ignored" is not bound.
>
>
> Any ideas why this happens?

Have you configured the hj prefix correctly?
Does it work in other places? Like normal elements and so on?

Bye.
/lexi