org.jboss.xb.annotations
Annotation Type JBossXmlNsPrefix
@Target(value={FIELD,METHOD})
@Retention(value=RUNTIME)
public @interface JBossXmlNsPrefix
Sometimes, it is desirable to bind a class into different schemas
with different namespaces or bind a class hierarchy into a specific
target namespace and some of the classes into a different namespace
the value of which depends on the root element's namespace.
XmlElement's namespace attribute cannot be used in a case like that.
What we need is to specify a prefix instead of the namespace itself
and define the namespace to prefix mapping in the JBossXmlSchema annotation.
This annotation is used to reference a namespace by its prefix.
- Version:
- $Revision: 1.1 $
- Author:
- Alexey Loubyansky
|
Optional Element Summary |
boolean |
schemaTargetIfNotMapped
If the prefix mapping is not found and the value is true
then the target schema namespace will be used, if the value is
false then an exception will be thrown. |
prefix
public abstract String prefix
schemaTargetIfNotMapped
public abstract boolean schemaTargetIfNotMapped
- If the prefix mapping is not found and the value is true
then the target schema namespace will be used, if the value is
false then an exception will be thrown.
- Returns:
- Default:
- false
Copyright © 2007 JBoss Inc.. All Rights Reserved.