Class GroupNameReplaceOperation<R>
- java.lang.Object
-
- org.dspace.app.rest.repository.patch.operation.PatchOperation<R>
-
- org.dspace.app.rest.repository.patch.operation.GroupNameReplaceOperation<R>
-
@Component public class GroupNameReplaceOperation<R> extends PatchOperation<R>
Implementation for Group name replacement patches. Example:curl -X PATCH http://${dspace.server.url}/api/epersons/groups/<:id-group> -H " Content-Type: application/json" -d '[{ "op": "replace", "path": " /name", "value": "new name"]'
-
-
Field Summary
-
Fields inherited from class org.dspace.app.rest.repository.patch.operation.PatchOperation
OPERATION_ADD, OPERATION_COPY, OPERATION_MOVE, OPERATION_REMOVE, OPERATION_REPLACE
-
-
Constructor Summary
Constructors Constructor Description GroupNameReplaceOperation()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Rperform(org.dspace.core.Context context, R object, Operation operation)Updates the rest model by applying the patch operation.booleansupports(Object objectToMatch, Operation operation)Determines whether or not this Patch Operation can do this patch (Object of operation and path gets checked)-
Methods inherited from class org.dspace.app.rest.repository.patch.operation.PatchOperation
checkOperationValue
-
-
-
-
Method Detail
-
perform
public R perform(org.dspace.core.Context context, R object, Operation operation)
Description copied from class:PatchOperationUpdates the rest model by applying the patch operation.- Specified by:
performin classPatchOperation<R>- Parameters:
context- context of patch operationobject- the dso.operation- the patch operation.- Returns:
- the patched dso
-
supports
public boolean supports(Object objectToMatch, Operation operation)
Description copied from class:PatchOperationDetermines whether or not this Patch Operation can do this patch (Object of operation and path gets checked)- Specified by:
supportsin classPatchOperation<R>- Parameters:
objectToMatch- Object whose class must be instance of type object for which this PatchOperation was createdoperation- Operation of the patch, should match this type of Patch Operation- Returns:
- True if this PatchOperation class can do the patch for this given dso type and Path
-
-