org.codehaus.xfire.type
Class CustomTypeMapping

java.lang.Object
  extended by org.codehaus.xfire.type.CustomTypeMapping
All Implemented Interfaces:
TypeMapping
Direct Known Subclasses:
AutoTypeMapping

public class CustomTypeMapping
extends java.lang.Object
implements TypeMapping

Contains type mappings for java/qname pairs and Serializer/Deserializer factories.

Since:
Feb 21, 2004
Author:
Dan Diephouse

Constructor Summary
CustomTypeMapping()
           
CustomTypeMapping(TypeMapping defaultTM)
           
 
Method Summary
 java.lang.String getEncodingStyleURI()
           
 Type getType(java.lang.Class javaType)
           
 Type getType(java.lang.Class javaType, javax.xml.namespace.QName xmlType)
           
 Type getType(javax.xml.namespace.QName xmlType)
           
 javax.xml.namespace.QName getTypeQName(java.lang.Class clazz)
           
 boolean isRegistered(java.lang.Class javaType, javax.xml.namespace.QName xmlType)
          Checks whether or not type mapping between specified XML type and Java type is registered.
 void register(java.lang.Class javaType, javax.xml.namespace.QName xmlType, Type type)
           
 void removeType(java.lang.Class javaType, javax.xml.namespace.QName xmlType)
           
 void setEncodingStyleURI(java.lang.String encodingStyleURI)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CustomTypeMapping

public CustomTypeMapping(TypeMapping defaultTM)

CustomTypeMapping

public CustomTypeMapping()
Method Detail

isRegistered

public boolean isRegistered(java.lang.Class javaType,
                            javax.xml.namespace.QName xmlType)
Description copied from interface: TypeMapping
Checks whether or not type mapping between specified XML type and Java type is registered.

Specified by:
isRegistered in interface TypeMapping
Parameters:
javaType - Class of the Java type
xmlType - Qualified name of the XML data type
Returns:
boolean; true if type mapping between the specified XML type and Java type is registered; otherwise false
See Also:
TypeMapping.isRegistered(java.lang.Class, javax.xml.namespace.QName)

register

public void register(java.lang.Class javaType,
                     javax.xml.namespace.QName xmlType,
                     Type type)
Specified by:
register in interface TypeMapping
See Also:
org.codehaus.xfire.type.TypeMapping#register(java.lang.Class, javax.xml.namespace.QName, org.codehaus.xfire.java.encoding.SerializerFactory, org.codehaus.xfire.java.encoding.DeserializerFactory)

getType

public Type getType(java.lang.Class javaType,
                    javax.xml.namespace.QName xmlType)
Specified by:
getType in interface TypeMapping
See Also:
org.codehaus.xfire.type.TypeMapping#getSerializer(java.lang.Class, javax.xml.namespace.QName)

removeType

public void removeType(java.lang.Class javaType,
                       javax.xml.namespace.QName xmlType)
Specified by:
removeType in interface TypeMapping
See Also:
org.codehaus.xfire.type.TypeMapping#removeSerializer(java.lang.Class, javax.xml.namespace.QName)

getType

public Type getType(java.lang.Class javaType)
Specified by:
getType in interface TypeMapping
See Also:
TypeMapping.getType(java.lang.Class)

getType

public Type getType(javax.xml.namespace.QName xmlType)
Specified by:
getType in interface TypeMapping
See Also:
TypeMapping.getType(javax.xml.namespace.QName)

getTypeQName

public javax.xml.namespace.QName getTypeQName(java.lang.Class clazz)
Specified by:
getTypeQName in interface TypeMapping
See Also:
TypeMapping.getTypeQName(java.lang.Class)

getEncodingStyleURI

public java.lang.String getEncodingStyleURI()
Specified by:
getEncodingStyleURI in interface TypeMapping

setEncodingStyleURI

public void setEncodingStyleURI(java.lang.String encodingStyleURI)
Specified by:
setEncodingStyleURI in interface TypeMapping


Copyright © 2004-2005 Codehaus. All Rights Reserved.