java.lang.Object
software.xdev.spring.data.eclipse.store.repository.query.ReflectedField<T,E>
Type Parameters:
T - Input
E - Value

public class ReflectedField<T,E> extends Object
Simple wrapper for a field to make it easily readable. If the fields is not accessible, it is made accessible with the AccessHelper.readFieldVariable(Field, Object).
  • Constructor Details

    • ReflectedField

      public ReflectedField(Field field)
  • Method Details

    • createReflectedField

      public static <T, E> ReflectedField<T,E> createReflectedField(Class<T> domainClass, String fieldName)
    • readValue

      public E readValue(@Nonnull T object)
      Reads the field of the given object. If the fields is not accessible, it is made accessible with the AccessHelper.readFieldVariable(Field, Object).
      Parameters:
      object - to read the field of
      Returns:
      value of the field in the given object.