Package io.milton.http
Class DeleteHelperImpl
java.lang.Object
io.milton.http.DeleteHelperImpl
- All Implemented Interfaces:
DeleteHelper
Default implementation of DeleteHelper
It will delegate to the resource if it implements
DeletableCollectionResource, otherwise it will walk the collection if its a
CollectionResource, and finally will just call handlerHelper.isLockedOut
otherwise
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoiddelete(DeletableResource r, EventManager eventManager) Delete the resource and any child resources The implementation should fire delete events for all resources physically deleted.booleanisLockedOut(Request req, Resource r) Check if the resource or any child resources are locked or otherwise not deletable
-
Constructor Details
-
DeleteHelperImpl
-
-
Method Details
-
isLockedOut
public boolean isLockedOut(Request req, Resource r) throws NotAuthorizedException, BadRequestException Description copied from interface:DeleteHelperCheck if the resource or any child resources are locked or otherwise not deletable- Specified by:
isLockedOutin interfaceDeleteHelper- Returns:
- Throws:
NotAuthorizedExceptionBadRequestException
-
delete
public void delete(DeletableResource r, EventManager eventManager) throws NotAuthorizedException, ConflictException, BadRequestException Description copied from interface:DeleteHelperDelete the resource and any child resources The implementation should fire delete events for all resources physically deleted.- Specified by:
deletein interfaceDeleteHelper- Throws:
NotAuthorizedExceptionConflictExceptionBadRequestException
-