Class MethodProperty

java.lang.Object
com.googlecode.objectify.impl.AbstractProperty
com.googlecode.objectify.impl.MethodProperty
All Implemented Interfaces:
Property

public class MethodProperty
extends AbstractProperty
Property which encapsulates a method with an @AlsoLoad parameter. If you try to get() the value it is always null.
  • Constructor Details

    • MethodProperty

      public MethodProperty(Method method)
  • Method Details

    • getType

      public Type getType()
      Description copied from interface: Property
      Get the real generic type of the field
    • set

      public void set(Object pojo, Object value)
      Description copied from interface: Property
      Actually set the property (field or method) on an object
    • get

      public Object get(Object pojo)
      Description copied from interface: Property
      Get the value of the property (field) if possible, or null if not possible (method)
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • isSaved

      public boolean isSaved(Object onPojo)
      Never saved
      Returns:
      true if this field should be saved, false if not
    • getIndexInstruction

      public Boolean getIndexInstruction(Object onPojo)
      Since we are never saved this is never called
      Returns:
      true if this field should be indexed, false if it should be unindexed, null is "no information, continue with defaults".