public class LiteralPropertyConduit extends PropertyConduitDelegate implements InternalPropertyConduit
Constructor and Description |
---|
LiteralPropertyConduit(TypeCoercer typeCoercer,
java.lang.Class propertyType,
AnnotationProvider annotationProvider,
java.lang.String description,
java.lang.Object value) |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
get(java.lang.Object instance)
Reads the property from the instance.
|
<T extends java.lang.annotation.Annotation> |
getAnnotation(java.lang.Class<T> annotationClass)
Searches for the specified annotation, returning the matching annotation instance.
|
java.lang.reflect.Type |
getPropertyGenericType()
Returns the generic type of the property
|
java.lang.String |
getPropertyName()
Returns the name of the property read or updated by the conduit or null.
|
java.lang.Class |
getPropertyType()
Returns the type of the property read or updated by the conduit.
|
void |
set(java.lang.Object instance,
java.lang.Object value)
Changes the current value of the property.
|
java.lang.String |
toString() |
coerce, invert, range
public LiteralPropertyConduit(TypeCoercer typeCoercer, java.lang.Class propertyType, AnnotationProvider annotationProvider, java.lang.String description, java.lang.Object value)
public java.lang.Object get(java.lang.Object instance)
PropertyConduit
get
in interface PropertyConduit
instance
- object containing the propertypublic void set(java.lang.Object instance, java.lang.Object value)
PropertyConduit
set
in interface PropertyConduit
instance
- object containing the propertyvalue
- to change the property topublic java.lang.Class getPropertyType()
PropertyConduit
getPropertyType
in interface PropertyConduit
public java.lang.reflect.Type getPropertyGenericType()
PropertyConduit2
getPropertyGenericType
in interface PropertyConduit2
Method.getGenericReturnType()
,
Field.getGenericType()
public <T extends java.lang.annotation.Annotation> T getAnnotation(java.lang.Class<T> annotationClass)
AnnotationProvider
getAnnotation
in interface AnnotationProvider
annotationClass
- used to select the annotation to returnpublic java.lang.String getPropertyName()
InternalPropertyConduit
null
.getPropertyName
in interface InternalPropertyConduit
null
public java.lang.String toString()
toString
in class java.lang.Object
${project.version} - Copyright © 2003-2015 The Apache Software Foundation.