Package org.jibx.schema.support
Class QNameConverter
- java.lang.Object
-
- org.jibx.schema.support.QNameConverter
-
public class QNameConverter extends Object
Qualified name serializer/deserializer for use in schema definitions. This uses special handling for values using the default namespace, checking if the schema being processed is a no-namespace schema being included into a schema with a namespace. If it is, the including namespace is used as the default.- Author:
- Dennis M. Sosnoski
-
-
Constructor Summary
Constructors Constructor Description QNameConverter()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidpatchQNameNamespace(String uri, org.jibx.runtime.QName qname)Patch qualified name with effective namespace from schema.static Stringserialize(org.jibx.runtime.QName qname, org.jibx.runtime.IMarshallingContext ictx)Qualified name serializer method for use within schema definitions.static StringserializeList(org.jibx.runtime.QName[] qnames, org.jibx.runtime.IMarshallingContext ictx)Qualified name list serializer method for use within schema definitions.
-
-
-
Method Detail
-
serialize
public static String serialize(org.jibx.runtime.QName qname, org.jibx.runtime.IMarshallingContext ictx) throws org.jibx.runtime.JiBXException
Qualified name serializer method for use within schema definitions.- Parameters:
qname- value to be serializedictx- unmarshalling context- Returns:
- created class instance
- Throws:
org.jibx.runtime.JiBXException- on error in marshalling
-
serializeList
public static String serializeList(org.jibx.runtime.QName[] qnames, org.jibx.runtime.IMarshallingContext ictx) throws org.jibx.runtime.JiBXException
Qualified name list serializer method for use within schema definitions.- Parameters:
qnames- array of names to be serializedictx- unmarshalling context- Returns:
- generated text
- Throws:
org.jibx.runtime.JiBXException- on error in marshalling
-
patchQNameNamespace
public static void patchQNameNamespace(String uri, org.jibx.runtime.QName qname)
Patch qualified name with effective namespace from schema. If the qualified name does not have a namespace, this uses the namespace from the schema.- Parameters:
uri- effective namespace URI from schemaqname- qualified name (call ignored ifnull)
-
-