org.apache.cxf.aegis.type
Class TypeUtil

java.lang.Object
  extended by org.apache.cxf.aegis.type.TypeUtil

public final class TypeUtil
extends java.lang.Object

Static methods/constants for Aegis.

Author:
Dan Diephouse

Field Summary
static java.util.logging.Logger LOG
           
 
Method Summary
static Type getReadType(javax.xml.stream.XMLStreamReader xsr, AegisContext context, Type baseType)
           
static Type getReadTypeStandalone(javax.xml.stream.XMLStreamReader xsr, AegisContext context, Type baseType)
          getReadType cannot just look up the xsi:type in the mapping.
static Type getWriteType(AegisContext globalContext, java.lang.Object value, Type type)
           
static Type getWriteTypeStandalone(AegisContext globalContext, java.lang.Object value, Type type)
           
static Type getWriteTypeStandalone(AegisContext globalContext, java.lang.Object value, java.lang.reflect.Type reflectType)
          Allow writing of collections when the type of the collection object is known via an Type object.
static void setAttributeAttributes(javax.xml.namespace.QName name, Type type, org.apache.ws.commons.schema.XmlSchema root)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOG

public static final java.util.logging.Logger LOG
Method Detail

getReadType

public static Type getReadType(javax.xml.stream.XMLStreamReader xsr,
                               AegisContext context,
                               Type baseType)

getReadTypeStandalone

public static Type getReadTypeStandalone(javax.xml.stream.XMLStreamReader xsr,
                                         AegisContext context,
                                         Type baseType)
getReadType cannot just look up the xsi:type in the mapping. This function must be called instead at the root where there is no initial mapping to start from, as from a part or an element of some containing item.

Parameters:
xsr -
context -
Returns:

getWriteType

public static Type getWriteType(AegisContext globalContext,
                                java.lang.Object value,
                                Type type)

getWriteTypeStandalone

public static Type getWriteTypeStandalone(AegisContext globalContext,
                                          java.lang.Object value,
                                          Type type)

getWriteTypeStandalone

public static Type getWriteTypeStandalone(AegisContext globalContext,
                                          java.lang.Object value,
                                          java.lang.reflect.Type reflectType)
Allow writing of collections when the type of the collection object is known via an Type object.

Parameters:
globalContext - the context
value - the object to write.
reflectType - the type to use in writing the object.
Returns:

setAttributeAttributes

public static void setAttributeAttributes(javax.xml.namespace.QName name,
                                          Type type,
                                          org.apache.ws.commons.schema.XmlSchema root)


Apache CXF