Package com.logicaldoc.webdav.resource
Class VersionControlledResourceImpl
- java.lang.Object
-
- com.logicaldoc.webdav.resource.DavResourceImpl
-
- com.logicaldoc.webdav.resource.DeltaVResourceImpl
-
- com.logicaldoc.webdav.resource.VersionControlledResourceImpl
-
- All Implemented Interfaces:
Serializable
,org.apache.jackrabbit.webdav.DavResource
,org.apache.jackrabbit.webdav.version.DeltaVResource
,org.apache.jackrabbit.webdav.version.VersionableResource
,org.apache.jackrabbit.webdav.version.VersionControlledResource
public class VersionControlledResourceImpl extends DeltaVResourceImpl implements org.apache.jackrabbit.webdav.version.VersionControlledResource, Serializable
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from interface org.apache.jackrabbit.webdav.version.DeltaVResource
METHODS, METHODS_INCL_MKWORKSPACE
-
Fields inherited from interface org.apache.jackrabbit.webdav.version.VersionControlledResource
ACTIVITY_SET, AUTO_MERGE_SET, AUTO_VERSION, BASELINE_CONTROLLED_COLLECTION, CHECKED_IN, CHECKED_OUT, CHECKIN_FORK, CHECKOUT_FORK, ECLIPSED_SET, MERGE_SET, methods_checkedIn, methods_checkedOut, PREDECESSOR_SET, SUBBASELINE_SET, UNRESERVED, VERSION_HISTORY
-
-
Constructor Summary
Constructors Constructor Description VersionControlledResourceImpl(org.apache.jackrabbit.webdav.DavResourceLocator locator, DavResourceFactory factory, DavSession session, ResourceConfig config)
Create a newDavResource
.VersionControlledResourceImpl(org.apache.jackrabbit.webdav.DavResourceLocator locator, DavResourceFactory factory, DavSession session, ResourceConfig config, boolean isCollection)
Create a newDavResource
.VersionControlledResourceImpl(org.apache.jackrabbit.webdav.DavResourceLocator locator, DavResourceFactory factory, DavSession session, ResourceConfig config, Resource resource)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addVersionControl()
Adds version control to this resource.String
checkin()
CallsNode.checkin()
on the underlying repository node.void
checkout()
CallsNode.checkout()
on the underlying repository nodeString
getSupportedMethods()
Return a comma separated string listing the supported method namesorg.apache.jackrabbit.webdav.version.VersionHistoryResource
getVersionHistory()
Returns theVersionHistory
associated with the repository node.void
label(org.apache.jackrabbit.webdav.version.LabelInfo labelInfo)
Modify the labels present with the versions of this resource.org.apache.jackrabbit.webdav.MultiStatus
merge(org.apache.jackrabbit.webdav.version.MergeInfo mergeInfo)
MERGE feature is not (yet) supported.void
uncheckout()
org.apache.jackrabbit.webdav.MultiStatus
update(org.apache.jackrabbit.webdav.version.UpdateInfo updateInfo)
UPDATE feature is not (yet) supported.-
Methods inherited from class com.logicaldoc.webdav.resource.DeltaVResourceImpl
addWorkspace, getComplianceClass, getOptionResponse, getReferenceResources, getReport
-
Methods inherited from class com.logicaldoc.webdav.resource.DavResourceImpl
addLockManager, addMember, alterProperties, alterProperties, copy, exists, getCollection, getDisplayName, getExportContext, getFactory, getHref, getLocator, getLock, getLocks, getMembers, getModificationTime, getProperties, getProperty, getPropertyNames, getResourcePath, getSession, hasLock, isCollection, isLockable, lock, move, refreshLock, removeMember, removeProperty, setProperty, spool, unlock
-
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.jackrabbit.webdav.DavResource
addLockManager, addMember, alterProperties, copy, exists, getCollection, getComplianceClass, getDisplayName, getFactory, getHref, getLocator, getLock, getLocks, getMembers, getModificationTime, getProperties, getProperty, getPropertyNames, getResourcePath, getSession, hasLock, isCollection, isLockable, lock, move, refreshLock, removeMember, removeProperty, setProperty, spool, unlock
-
-
-
-
Constructor Detail
-
VersionControlledResourceImpl
public VersionControlledResourceImpl(org.apache.jackrabbit.webdav.DavResourceLocator locator, DavResourceFactory factory, DavSession session, ResourceConfig config, Resource resource) throws org.apache.jackrabbit.webdav.DavException
- Throws:
org.apache.jackrabbit.webdav.DavException
-
VersionControlledResourceImpl
public VersionControlledResourceImpl(org.apache.jackrabbit.webdav.DavResourceLocator locator, DavResourceFactory factory, DavSession session, ResourceConfig config) throws org.apache.jackrabbit.webdav.DavException
Create a newDavResource
.- Parameters:
locator
- resource locatorfactory
- factorysession
- the DAV sessionconfig
- configurations- Throws:
org.apache.jackrabbit.webdav.DavException
- error in the DAV communication
-
VersionControlledResourceImpl
public VersionControlledResourceImpl(org.apache.jackrabbit.webdav.DavResourceLocator locator, DavResourceFactory factory, DavSession session, ResourceConfig config, boolean isCollection) throws org.apache.jackrabbit.webdav.DavException
Create a newDavResource
.- Parameters:
locator
- resource locatorfactory
- factorysession
- the DAV sessionconfig
- configurationsisCollection
- is this a folder?- Throws:
org.apache.jackrabbit.webdav.DavException
- error in the DAV communication
-
-
Method Detail
-
getSupportedMethods
public String getSupportedMethods()
Return a comma separated string listing the supported method names- Specified by:
getSupportedMethods
in interfaceorg.apache.jackrabbit.webdav.DavResource
- Overrides:
getSupportedMethods
in classDavResourceImpl
- Returns:
- the supported method names
- See Also:
DavResource.getSupportedMethods()
-
addVersionControl
public void addVersionControl() throws org.apache.jackrabbit.webdav.DavException
Adds version control to this resource. If the resource is already under version control, this method has no effect. If this resource is a Collection resource this method fails withHttpServletResponse.SC_METHOD_NOT_ALLOWED
.- Specified by:
addVersionControl
in interfaceorg.apache.jackrabbit.webdav.version.VersionableResource
- Throws:
org.apache.jackrabbit.webdav.DavException
- if this resource does not exist yet, is a collection or if an error occurs while making the underlying node versionable.- See Also:
VersionableResource.addVersionControl()
-
checkin
public String checkin() throws org.apache.jackrabbit.webdav.DavException
CallsNode.checkin()
on the underlying repository node.- Specified by:
checkin
in interfaceorg.apache.jackrabbit.webdav.version.VersionControlledResource
- Throws:
org.apache.jackrabbit.webdav.DavException
- error in the DAV communication- See Also:
VersionControlledResource.checkin()
-
checkout
public void checkout() throws org.apache.jackrabbit.webdav.DavException
CallsNode.checkout()
on the underlying repository node- Specified by:
checkout
in interfaceorg.apache.jackrabbit.webdav.version.VersionControlledResource
- Throws:
org.apache.jackrabbit.webdav.DavException
- error in the DAV communication- See Also:
VersionControlledResource.checkout()
-
uncheckout
public void uncheckout() throws org.apache.jackrabbit.webdav.DavException
- Specified by:
uncheckout
in interfaceorg.apache.jackrabbit.webdav.version.VersionControlledResource
- Throws:
org.apache.jackrabbit.webdav.DavException
- error in the DAV communication- See Also:
VersionControlledResource.uncheckout()
-
update
public org.apache.jackrabbit.webdav.MultiStatus update(org.apache.jackrabbit.webdav.version.UpdateInfo updateInfo) throws org.apache.jackrabbit.webdav.DavException
UPDATE feature is not (yet) supported. This method allows fails withHttpServletResponse.SC_NOT_IMPLEMENTED
.- Specified by:
update
in interfaceorg.apache.jackrabbit.webdav.version.VersionControlledResource
- Parameters:
updateInfo
- update datails- Returns:
- the status
- Throws:
org.apache.jackrabbit.webdav.DavException
- error in the DAV communication- See Also:
VersionControlledResource.update(UpdateInfo)
-
merge
public org.apache.jackrabbit.webdav.MultiStatus merge(org.apache.jackrabbit.webdav.version.MergeInfo mergeInfo) throws org.apache.jackrabbit.webdav.DavException
MERGE feature is not (yet) supported. This method allows fails withHttpServletResponse.SC_NOT_IMPLEMENTED
.- Specified by:
merge
in interfaceorg.apache.jackrabbit.webdav.version.VersionControlledResource
- Parameters:
mergeInfo
- details bout the merge- Returns:
- the status
- Throws:
org.apache.jackrabbit.webdav.DavException
- error in the DAV communication- See Also:
VersionControlledResource.merge(MergeInfo)
-
label
public void label(org.apache.jackrabbit.webdav.version.LabelInfo labelInfo) throws org.apache.jackrabbit.webdav.DavException
Modify the labels present with the versions of this resource.- Specified by:
label
in interfaceorg.apache.jackrabbit.webdav.version.VersionControlledResource
- Parameters:
labelInfo
- details of the label- Throws:
org.apache.jackrabbit.webdav.DavException
- error in the DAV communication- See Also:
VersionControlledResource.label(LabelInfo)
,VersionHistory.addVersionLabel(String, String, boolean)
,VersionHistory.removeVersionLabel(String)
-
getVersionHistory
public org.apache.jackrabbit.webdav.version.VersionHistoryResource getVersionHistory()
Returns theVersionHistory
associated with the repository node. If the node is not versionable an exception is thrown.- Specified by:
getVersionHistory
in interfaceorg.apache.jackrabbit.webdav.version.VersionControlledResource
- Returns:
- the
VersionHistoryResource
associated with this resource. - See Also:
VersionControlledResource.getVersionHistory()
,Node.getVersionHistory()
-
-