Groovy Documentation

src.java.org.grails.xfire.aegis.type.basic
Class BeanType

java.lang.Object
  org.grails.xfire.aegis.type.Type
      src.java.org.grails.xfire.aegis.type.basic.BeanType

class BeanType
extends Type

Serializes JavaBeans.

author:
Dan Diephouse
author:
Jack Hong


Field Summary
private BeanTypeInfo _info

private boolean isException

private boolean isInterface

 
Constructor Summary
BeanType()

BeanType(BeanTypeInfo info)

 
Method Summary
private Element createAnyAttribute()

Create an element to represent any future attributes that might get added to the schema

private Element createAnyElement()

Create an element to represent any future elements that might get added to the schema

protected java.lang.Object createFromFault(MessageContext context)

If the class is an exception, this will try and instantiate it with information from the XFireFault (if it exists).

BeanTypeInfo createTypeInfo()

private BeanType getBeanTypeWithProperty(QName name)

Set getDependencies()

private java.lang.String getNameWithPrefix(Element root, java.lang.String nameNS, java.lang.String localName)

if future proof then add element

private java.lang.String getNameWithPrefix2(Element root, java.lang.String nameNS, java.lang.String localName)

private BeanType getSuperType()

private Type getType(BeanTypeInfo info, QName name)

BeanTypeInfo getTypeInfo()

private Method getWriteMethodFromImplClass(java.lang.Class impl, PropertyDescriptor pd)

This is a hack to get the write method from the implementation class for an interface.

private MessageWriter getWriter(MessageWriter writer, QName name, Type type)

boolean isComplex()

We need to write a complex type schema for Beans, so return true.

java.lang.Object readObject(MessageReader reader, MessageContext context)

protected java.lang.Object readProperty(java.lang.Object object, QName name)

void setTypeClass(java.lang.Class typeClass)

java.lang.String toString()

void writeObject(java.lang.Object object, MessageWriter writer, MessageContext context)

org.grails.xfire.aegis.MessageWriter, org.codehaus.xfire.MessageContext)

protected void writeProperty(QName name, java.lang.Object object, java.lang.Object property, java.lang.Class impl, BeanTypeInfo info)

Write the specified property to a field.

void writeSchema(Element root)

private void writeTypeReference(QName name, java.lang.String nameWithPrefix, Element element, Type type, java.lang.String prefix)

 

Field Detail

_info

private BeanTypeInfo _info


isException

private boolean isException


isInterface

private boolean isInterface


 
Constructor Detail

BeanType

public BeanType()


BeanType

public BeanType(BeanTypeInfo info)


 
Method Detail

createAnyAttribute

private Element createAnyAttribute()
Create an element to represent any future attributes that might get added to the schema
return:


createAnyElement

private Element createAnyElement()
Create an element to represent any future elements that might get added to the schema
return:


createFromFault

protected java.lang.Object createFromFault(MessageContext context)
If the class is an exception, this will try and instantiate it with information from the XFireFault (if it exists).


createTypeInfo

public BeanTypeInfo createTypeInfo()


getBeanTypeWithProperty

private BeanType getBeanTypeWithProperty(QName name)


getDependencies

public Set getDependencies()


getNameWithPrefix

private java.lang.String getNameWithPrefix(Element root, java.lang.String nameNS, java.lang.String localName)
if future proof then add element


getNameWithPrefix2

private java.lang.String getNameWithPrefix2(Element root, java.lang.String nameNS, java.lang.String localName)


getSuperType

private BeanType getSuperType()


getType

private Type getType(BeanTypeInfo info, QName name)


getTypeInfo

public BeanTypeInfo getTypeInfo()


getWriteMethodFromImplClass

private Method getWriteMethodFromImplClass(java.lang.Class impl, PropertyDescriptor pd)
This is a hack to get the write method from the implementation class for an interface.


getWriter

private MessageWriter getWriter(MessageWriter writer, QName name, Type type)


isComplex

public boolean isComplex()
We need to write a complex type schema for Beans, so return true.
see:
org.grails.xfire.aegis.type.Type#isComplex()


readObject

public java.lang.Object readObject(MessageReader reader, MessageContext context)


readProperty

protected java.lang.Object readProperty(java.lang.Object object, QName name)


setTypeClass

public void setTypeClass(java.lang.Class typeClass)


toString

public java.lang.String toString()


writeObject

public void writeObject(java.lang.Object object, MessageWriter writer, MessageContext context)
see:
org.grails.xfire.aegis.type.Type#writeObject(Object, org.grails.xfire.aegis.MessageWriter, org.codehaus.xfire.MessageContext)


writeProperty

protected void writeProperty(QName name, java.lang.Object object, java.lang.Object property, java.lang.Class impl, BeanTypeInfo info)
Write the specified property to a field.


writeSchema

public void writeSchema(Element root)
see:
org.grails.xfire.aegis.type.Type#writeSchema(org.jdom.Element)


writeTypeReference

private void writeTypeReference(QName name, java.lang.String nameWithPrefix, Element element, Type type, java.lang.String prefix)


 

Groovy Documentation