Package org.apache.cxf.aegis.type
Interface TypeMapping
-
- All Known Implementing Classes:
DefaultTypeMapping
public interface TypeMappingAbstraction for the map between Java types (represented asTypeand Aegis types.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description StringgetMappingIdentifierURI()Each mapping has a URI that identifies it.AegisTypegetType(Type javaType)AegisTypegetType(QName xmlType)TypeCreatorgetTypeCreator()QNamegetTypeQName(Type clazz)booleanisRegistered(Type javaType)Returns a flag indicating if this type mapping has a mapping for a particular Java class.booleanisRegistered(QName xmlType)Returns a flag indicating if this type mapping has a mapping for a particular XML Schema QName.voidregister(Type javaType, QName xmlType, AegisType type)Register a type, manually specifying the java class, the schema type, and the Aegis type object that provides serialization, deserialization, and schema.voidregister(AegisType type)Register a type that self-describes the schema type and the Java class.voidremoveType(AegisType type)voidsetMappingIdentifierURI(String uri)This exists only to deal with an initialization order problem.
-
-
-
Method Detail
-
isRegistered
boolean isRegistered(Type javaType)
Returns a flag indicating if this type mapping has a mapping for a particular Java class.- Parameters:
javaType- the class.- Returns:
trueif there is a mapping for the type.
-
isRegistered
boolean isRegistered(QName xmlType)
Returns a flag indicating if this type mapping has a mapping for a particular XML Schema QName.- Parameters:
xmlType- the QName.- Returns:
trueif there is a mapping for the type.
-
register
void register(Type javaType, QName xmlType, AegisType type)
Register a type, manually specifying the java class, the schema type, and the Aegis type object that provides serialization, deserialization, and schema.- Parameters:
javaType- Java class.xmlType- XML Schema type QName.type- Aegis type object.
-
register
void register(AegisType type)
Register a type that self-describes the schema type and the Java class.- Parameters:
type- Aegis type object that
-
removeType
void removeType(AegisType type)
-
getTypeCreator
TypeCreator getTypeCreator()
-
getMappingIdentifierURI
String getMappingIdentifierURI()
Each mapping has a URI that identifies it. The mapping for a service uses the service URI. XML files can choose to only contribute mappings that match.- Returns:
- the URI.
-
setMappingIdentifierURI
void setMappingIdentifierURI(String uri)
This exists only to deal with an initialization order problem.- Parameters:
uri-
-
-