Class PatchOperation


public abstract class PatchOperation extends Object
Abstract base class representing and providing support methods for patch operations.
Craig Walls, Mathias Düsterhöft, Oliver Gierke
  • Field Details

    • op

      protected final String op
    • path

      protected final path
    • value

      protected final Object value
  • Constructor Details

    • PatchOperation

      public PatchOperation(String op, path)
      Constructs the operation.
      op - the operation name. (e.g., 'move')
      path - the path to perform the operation on. (e.g., '/1/description')
    • PatchOperation

      protected PatchOperation(String op, path, Object value)
  • Method Details

    • evaluateValueFromTarget

      protected Object evaluateValueFromTarget(Object targetObject, Class<?> entityType, BindContext context)
      Performs late-value evaluation on the operation value if the value is a LateObjectEvaluator.
      targetObject - the target object, used as assistance in determining the evaluated object's type.
      entityType - the entityType
      the result of late-value evaluation if the value is a LateObjectEvaluator; the value itself otherwise.
    • evaluate

      protected final Object evaluate(Class<?> type)