Class SaveFieldManager

java.lang.Object
org.apache.openjpa.kernel.SaveFieldManager
All Implemented Interfaces:
Serializable, FieldConsumer, FieldManager, FieldSupplier

public class SaveFieldManager extends Object implements Serializable
FieldManager type used to store information for rollback.
Author:
Abe White
See Also:
  • Method Details

    • getState

      public PersistenceCapable getState()
      Return the persistence capable copy holding the rollback field values.
    • getUnloaded

      public BitSet getUnloaded()
      Return the currently-loaded fields that will be unloaded after rollback.
    • saveField

      public boolean saveField(int field)
      Save the given field. If this method returns true, then you need to use this field manager to replace the given field in the instance returned by getState().
    • restoreField

      public boolean restoreField(int field)
      Restore the given field. If this method returns true, then you need to use this field manager to replace the given field in the state manager's instance.
    • isFieldEqual

      public boolean isFieldEqual(int field, Object current)
      Compare the given field.
      Returns:
      true if the field is the same in the current state and in the saved state; otherwise, false.
    • fetchObjectField

      public Object fetchObjectField(int field)
      Description copied from interface: FieldSupplier
      Return the value of the given field.
      Specified by:
      fetchObjectField in interface FieldSupplier
    • storeObjectField

      public void storeObjectField(int field, Object curVal)
      Description copied from interface: FieldConsumer
      Set the value of the given field.
      Specified by:
      storeObjectField in interface FieldConsumer
    • getInstance

      public static org.apache.openjpa.kernel.ClearFieldManager getInstance()
    • fetchBooleanField

      public boolean fetchBooleanField(int field)
      Description copied from interface: FieldSupplier
      Return the value of the given field.
      Specified by:
      fetchBooleanField in interface FieldSupplier
    • fetchByteField

      public byte fetchByteField(int field)
      Description copied from interface: FieldSupplier
      Return the value of the given field.
      Specified by:
      fetchByteField in interface FieldSupplier
    • fetchCharField

      public char fetchCharField(int field)
      Description copied from interface: FieldSupplier
      Return the value of the given field.
      Specified by:
      fetchCharField in interface FieldSupplier
    • fetchDoubleField

      public double fetchDoubleField(int field)
      Description copied from interface: FieldSupplier
      Return the value of the given field.
      Specified by:
      fetchDoubleField in interface FieldSupplier
    • fetchFloatField

      public float fetchFloatField(int field)
      Description copied from interface: FieldSupplier
      Return the value of the given field.
      Specified by:
      fetchFloatField in interface FieldSupplier
    • fetchIntField

      public int fetchIntField(int field)
      Description copied from interface: FieldSupplier
      Return the value of the given field.
      Specified by:
      fetchIntField in interface FieldSupplier
    • fetchLongField

      public long fetchLongField(int field)
      Description copied from interface: FieldSupplier
      Return the value of the given field.
      Specified by:
      fetchLongField in interface FieldSupplier
    • fetchShortField

      public short fetchShortField(int field)
      Description copied from interface: FieldSupplier
      Return the value of the given field.
      Specified by:
      fetchShortField in interface FieldSupplier
    • fetchStringField

      public String fetchStringField(int field)
      Description copied from interface: FieldSupplier
      Return the value of the given field.
      Specified by:
      fetchStringField in interface FieldSupplier
    • storeBooleanField

      public void storeBooleanField(int field, boolean curVal)
      Description copied from interface: FieldConsumer
      Set the value of the given field.
      Specified by:
      storeBooleanField in interface FieldConsumer
    • storeByteField

      public void storeByteField(int field, byte curVal)
      Description copied from interface: FieldConsumer
      Set the value of the given field.
      Specified by:
      storeByteField in interface FieldConsumer
    • storeCharField

      public void storeCharField(int field, char curVal)
      Description copied from interface: FieldConsumer
      Set the value of the given field.
      Specified by:
      storeCharField in interface FieldConsumer
    • storeDoubleField

      public void storeDoubleField(int field, double curVal)
      Description copied from interface: FieldConsumer
      Set the value of the given field.
      Specified by:
      storeDoubleField in interface FieldConsumer
    • storeFloatField

      public void storeFloatField(int field, float curVal)
      Description copied from interface: FieldConsumer
      Set the value of the given field.
      Specified by:
      storeFloatField in interface FieldConsumer
    • storeIntField

      public void storeIntField(int field, int curVal)
      Description copied from interface: FieldConsumer
      Set the value of the given field.
      Specified by:
      storeIntField in interface FieldConsumer
    • storeLongField

      public void storeLongField(int field, long curVal)
      Description copied from interface: FieldConsumer
      Set the value of the given field.
      Specified by:
      storeLongField in interface FieldConsumer
    • storeShortField

      public void storeShortField(int field, short curVal)
      Description copied from interface: FieldConsumer
      Set the value of the given field.
      Specified by:
      storeShortField in interface FieldConsumer
    • storeStringField

      public void storeStringField(int field, String curVal)
      Description copied from interface: FieldConsumer
      Set the value of the given field.
      Specified by:
      storeStringField in interface FieldConsumer