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

java.lang.Object
  extended by com.sun.tools.xjc.api.impl.s2j.ElementAdapter
All Implemented Interfaces:
FieldOutline
Direct Known Subclasses:
ElementCollectionAdapter, ElementSingleAdapter

abstract class ElementAdapter
extends Object
implements FieldOutline

FieldOutline that wraps another FieldOutline and allows JAX-WS to access values without using about JAXBElement.

That means if a value is requested, we unwrap JAXBElement and give it to them. If a value is set, we wrap that into JAXBElement, etc.

This can be used only with CReferencePropertyInfo (or else it won't be JAXBElement), with one {@link CElementInfo} (or else we can't infer the tag name.)


Nested Class Summary
protected  class ElementAdapter.FieldAccessorImpl
           
 
Field Summary
protected  FieldOutline core
           
protected  CElementInfo ei
          The only one CElementInfo that can be in the property.
 
Constructor Summary
ElementAdapter(FieldOutline core, CElementInfo ei)
           
 
Method Summary
protected  com.sun.codemodel.JCodeModel codeModel()
           
 CPropertyInfo getPropertyInfo()
          Gets the corresponding model object.
protected  Outline outline()
           
 ClassOutline parent()
          Gets the enclosing ClassOutline.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.sun.tools.xjc.outline.FieldOutline
create, getRawType
 

Field Detail

core

protected final FieldOutline core

ei

protected final CElementInfo ei
The only one CElementInfo that can be in the property.

Constructor Detail

ElementAdapter

public ElementAdapter(FieldOutline core,
                      CElementInfo ei)
Method Detail

parent

public ClassOutline parent()
Description copied from interface: FieldOutline
Gets the enclosing ClassOutline.

Specified by:
parent in interface FieldOutline

getPropertyInfo

public CPropertyInfo getPropertyInfo()
Description copied from interface: FieldOutline
Gets the corresponding model object.

Specified by:
getPropertyInfo in interface FieldOutline

outline

protected final Outline outline()

codeModel

protected final com.sun.codemodel.JCodeModel codeModel()