Top Description Fields Constructors Methods
org.glassfish.jaxb.runtime.v2.model.impl

pack-priv Class GetterSetterPropertySeed<TypeT, ClassDeclT, FieldT, MethodT>

extends Object
implements PropertySeed<TypeT, ClassDeclT, FieldT, MethodT>
Class Inheritance
All Implemented Interfaces
org.glassfish.jaxb.runtime.v2.model.impl.PropertySeed, org.glassfish.jaxb.core.v2.model.annotation.AnnotationSource, org.glassfish.jaxb.core.v2.model.annotation.Locatable
Imports
org.glassfish.jaxb.core.v2.model.annotation.Locatable, org.glassfish.jaxb.core.v2.model.core.PropertyInfo, org.glassfish.jaxb.core.v2.runtime.Location, java.beans.Introspector, java.lang.annotation.Annotation

PropertyInfo implementation backed by a getter and a setter. We allow the getter or setter to be null, in which case the bean can only participate in unmarshalling (or marshalling)

Field Summary

Modifier and TypeField and Description
protected final MethodT
private ClassInfoImpl<TypeT, ClassDeclT, FieldT, MethodT>
protected final MethodT

Constructor Summary

AccessConstructor and Description
pack-priv
GetterSetterPropertySeed(ClassInfoImpl<TypeT, ClassDeclT, FieldT, MethodT> parent, MethodT getter, MethodT setter)

Method Summary

Modifier and TypeMethod and Description
private static String
public Location
getLocation()

Implements org.glassfish.jaxb.core.v2.model.annotation.Locatable.getLocation.

Gets the location object that this object points to.

public String
getName()

Implements org.glassfish.jaxb.runtime.v2.model.impl.PropertySeed.getName.

The name of the property is a spec defined concept --- although it doesn't do so explicitly in anywhere.

private String
getName(MethodT m)

public TypeT
getRawType()

Implements org.glassfish.jaxb.runtime.v2.model.impl.PropertySeed.getRawType.

Gets the actual data type of the field.

public Locatable
getUpstream()

Implements org.glassfish.jaxb.core.v2.model.annotation.Locatable.getUpstream.

Use the enclosing class as the upsream Location.

public boolean
hasAnnotation(Class<? extends Annotation> annotationType)

Implements org.glassfish.jaxb.core.v2.model.annotation.AnnotationSource.hasAnnotation.

Returns true if the property has the specified annotation.

public <A extends Annotation> A
readAnnotation(Class<A> annotation)

Implements org.glassfish.jaxb.core.v2.model.annotation.AnnotationSource.readAnnotation.

Gets the value of the specified annotation from the given property.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

getterback to summary
protected final MethodT getter
parentback to summary
private ClassInfoImpl<TypeT, ClassDeclT, FieldT, MethodT> parent
setterback to summary
protected final MethodT setter

Constructor Detail

GetterSetterPropertySeedback to summary
pack-priv GetterSetterPropertySeed(ClassInfoImpl<TypeT, ClassDeclT, FieldT, MethodT> parent, MethodT getter, MethodT setter)

Method Detail

camelizeback to summary
private static String camelize(String s)
getLocationback to summary
public Location getLocation()

Implements org.glassfish.jaxb.core.v2.model.annotation.Locatable.getLocation.

Doc from org.glassfish.jaxb.core.v2.model.annotation.Locatable.getLocation.

Gets the location object that this object points to. This operation could be inefficient and costly.

Annotations
@Override
getNameback to summary
public String getName()

Implements org.glassfish.jaxb.runtime.v2.model.impl.PropertySeed.getName.

Doc from org.glassfish.jaxb.runtime.v2.model.impl.PropertySeed.getName.

The name of the property is a spec defined concept --- although it doesn't do so explicitly in anywhere.

Annotations
@Override
getNameback to summary
private String getName(MethodT m)
getRawTypeback to summary
public TypeT getRawType()

Implements org.glassfish.jaxb.runtime.v2.model.impl.PropertySeed.getRawType.

Doc from org.glassfish.jaxb.runtime.v2.model.impl.PropertySeed.getRawType.

Gets the actual data type of the field.

The data of the property is stored by using this type.

The difference between the RuntimePropertyInfo#getIndividualType() and this method is clear when the property is a multi-value property. The RuntimePropertyInfo#getIndividualType() method returns the type of the item, but this method returns the actual collection type.

Annotations
@Override
getUpstreamback to summary
public Locatable getUpstream()

Implements org.glassfish.jaxb.core.v2.model.annotation.Locatable.getUpstream.

Use the enclosing class as the upsream Location.

Annotations
@Override
hasAnnotationback to summary
public boolean hasAnnotation(Class<? extends Annotation> annotationType)

Implements org.glassfish.jaxb.core.v2.model.annotation.AnnotationSource.hasAnnotation.

Doc from org.glassfish.jaxb.core.v2.model.annotation.AnnotationSource.hasAnnotation.

Returns true if the property has the specified annotation.

Short for readAnnotation(annotationType)!=null, but this method is typically faster.

Annotations
@Override
readAnnotationback to summary
public <A extends Annotation> A readAnnotation(Class<A> annotation)

Implements org.glassfish.jaxb.core.v2.model.annotation.AnnotationSource.readAnnotation.

Doc from org.glassfish.jaxb.core.v2.model.annotation.AnnotationSource.readAnnotation.

Gets the value of the specified annotation from the given property.

When this method is used for a property that consists of a getter and setter, it returns the annotation on either of those methods. If both methods have the same annotation, it is an error.

Annotations
@Override