Package io.milton.resource
Interface LockingCollectionResource
-
- All Superinterfaces:
CollectionResource,LockableResource,Resource
public interface LockingCollectionResource extends CollectionResource, LockableResource
A collection which allows locking "unmapped resources". This means that a LOCK method can effectively create an empty resource which is immediately locked. Implement this in conjunction with {@see LockableResource} on child resources to fully support locking. Note that this interface now extends {@see LockableResource} because collection resources need to implement both in most cases. If, however, you don't want your collection resources to be lockable, just implement {@see ConditionalCompatibleResource}. See http://www.ettrema.com:8080/browse/MIL-14.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description LockTokencreateAndLock(String name, LockTimeout timeout, LockInfo lockInfo)Create an empty non-collection resource of the given name and immediately lock it.-
Methods inherited from interface io.milton.resource.CollectionResource
child, getChildren
-
Methods inherited from interface io.milton.resource.LockableResource
getCurrentLock, lock, refreshLock, unlock
-
Methods inherited from interface io.milton.resource.Resource
authenticate, authorise, checkRedirect, getModifiedDate, getName, getRealm, getUniqueId
-
-
-
-
Method Detail
-
createAndLock
LockToken createAndLock(String name, LockTimeout timeout, LockInfo lockInfo) throws io.milton.http.exceptions.NotAuthorizedException
Create an empty non-collection resource of the given name and immediately lock it. It is suggested that the implementor have a specific Resource class to act as the lock null resource. You should consider using the {@see LockNullResource} interface.- Parameters:
name- - the name of the resource to createtimeout- - in secondslockInfo-- Returns:
- Throws:
io.milton.http.exceptions.NotAuthorizedException- See Also:
LockNullResource
-
-