Class RootValueRetrieverImpl<T>
java.lang.Object
net.officefloor.web.value.retrieve.RootValueRetrieverImpl<T>
- All Implemented Interfaces:
ValueRetriever<T>
ValueRetriever implementation.- Author:
- Daniel Sagenschneider
-
Constructor Summary
ConstructorsConstructorDescriptionRootValueRetrieverImpl(PropertyMetaData[] properties, boolean isCaseInsensitive) Initiate. -
Method Summary
Modifier and TypeMethodDescription<A> AgetValueAnnotation(String name, Class<A> annotationType) Obtains the value annotation for the property on the object graph.Class<?>getValueType(String name) Obtains the value type for the property on the object graph.retrieveValue(T object, String name) Retrieves the value from the object graph.
-
Constructor Details
-
RootValueRetrieverImpl
Initiate.- Parameters:
properties-PropertyMetaDatainstances.isCaseInsensitive- Indicates if case insensitive.
-
-
Method Details
-
getValueType
Description copied from interface:ValueRetrieverObtains the value type for the property on the object graph. It may benullindicating the path does not exist on the bean graph.- Specified by:
getValueTypein interfaceValueRetriever<T>- Parameters:
name- Property name.- Returns:
- Value type. May be
nullif the path not exists. - Throws:
HttpException- If fails to determine if value is retrievable.
-
getValueAnnotation
Description copied from interface:ValueRetrieverObtains the value annotation for the property on the object graph. It may benullindicating either:- the path does not exist on the bean graph, or
- no annotation by type for property
- Specified by:
getValueAnnotationin interfaceValueRetriever<T>- Type Parameters:
A-Annotationtype.- Parameters:
name- Property name.annotationType- Annotation type.- Returns:
- Annotation. May be
null. - Throws:
HttpException- If fails to obtain annotation.
-
retrieveValue
Description copied from interface:ValueRetrieverRetrieves the value from the object graph.- Specified by:
retrieveValuein interfaceValueRetriever<T>- Parameters:
object- Root object of the object graph.name- Property name.- Returns:
- Property value.
- Throws:
HttpException- If fails to retrieve the value.
-