com.sun.tools.xjc.api.impl.s2j
Class PropertyImpl

java.lang.Object
  extended by com.sun.tools.xjc.api.impl.s2j.PropertyImpl
All Implemented Interfaces:
Property

public final class PropertyImpl
extends Object
implements Property


Field Summary
protected  com.sun.codemodel.JCodeModel codeModel
           
protected  QName elementName
           
protected  FieldOutline fr
           
protected  Mapping parent
           
 
Constructor Summary
PropertyImpl(Mapping parent, FieldOutline fr, QName elementName)
           
 
Method Summary
 QName elementName()
          Name of the XML element that corresponds to the property.
 String name()
          The name of the property.
 com.sun.codemodel.JType type()
          The Java type of the property.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

fr

protected final FieldOutline fr

elementName

protected final QName elementName

parent

protected final Mapping parent

codeModel

protected final com.sun.codemodel.JCodeModel codeModel
Constructor Detail

PropertyImpl

PropertyImpl(Mapping parent,
             FieldOutline fr,
             QName elementName)
Method Detail

name

public final String name()
Description copied from interface: Property
The name of the property.

This method returns a valid identifier suitable for the use as a variable name.

Specified by:
name in interface Property
Returns:
always non-null. Camel-style name like "foo" or "barAndZot". Note that it may contain non-ASCII characters (CJK, etc.) The caller is responsible for proper escaping if it wants to print this as a variable name.

elementName

public final QName elementName()
Description copied from interface: Property
Name of the XML element that corresponds to the property.

Each child of a wrapper style element corresponds with an element, and this method returns that name.

Specified by:
elementName in interface Property
Returns:
always non-null valid QName.

type

public final com.sun.codemodel.JType type()
Description copied from interface: Property
The Java type of the property.

Specified by:
type in interface Property
Returns:
always non-null. JType is a representation of a Java type in a codeModel. If you just need the fully-qualified class name, call JType.fullName().