public class LockMethod extends WebDAVMethod
WebDAVMethod.Condition
Modifier and Type | Field and Description |
---|---|
protected boolean |
createExclusive |
static String |
EMPTY_NS |
protected LockInfo |
lockInfo |
protected String |
lockToken |
protected int |
m_timeoutDuration |
logger, m_childToParent, m_conditions, m_davHelper, m_depth, m_parentLockInfo, m_request, m_resourceTag, m_response, m_rootNodeRef, m_strPath, m_userAgent
Constructor and Description |
---|
LockMethod()
Default constructor
|
Modifier and Type | Method and Description |
---|---|
protected void |
attemptLock()
The main lock implementation method.
|
protected void |
createLock(FileInfo lockNode,
String userName)
Create a new lock
|
protected FileInfo |
createNode(org.alfresco.service.cmr.repository.NodeRef parentNodeRef,
String name,
org.alfresco.service.namespace.QName typeQName)
Create a new node
|
protected void |
executeImpl()
Execute the request
|
protected String |
generateNamespaceDeclarations(HashMap<String,String> nameSpaces)
Generates a list of namespace declarations for the response
|
protected void |
generateResponse(FileInfo lockNodeInfo,
String userName)
Generates the XML lock discovery response body
|
protected int |
getLockTimeout()
Return the lock timeout, in seconds.
|
protected boolean |
hasLockToken()
Returns true if request has lock token in the If header
|
protected void |
parseRequestBody()
Parse the request body
|
protected void |
parseRequestHeaders()
Parse the request headers
|
protected void |
refreshLock(FileInfo lockNode,
String userName)
Refresh an existing lock
|
checkNode, checkNode, createXMLWriter, execute, flushXML, generateLockDiscoveryXML, generateLockDiscoveryXML, generateResponseImpl, getActionService, getAuthenticationService, getContentService, getContextPath, getDAVHelper, getDAVLockService, getDepth, getFileFolderService, getMimetypeService, getNamespaceService, getNodeForPath, getNodeLockInfo, getNodeService, getPath, getPermissionService, getRequestBodyAsDocument, getRootNodeRef, getSearchService, getServiceRegistry, getServletPath, getSiteId, getStatusForAccessDeniedException, getTenantDomain, getTransactionService, getURLForPath, getWorkingCopy, getXMLOutputFormat, isReadOnly, parseDepthHeader, parseIfHeader, setDetails, shouldFlushXMLWriter, toString
public static final String EMPTY_NS
protected int m_timeoutDuration
protected LockInfo lockInfo
protected boolean createExclusive
protected String lockToken
protected final boolean hasLockToken()
protected final int getLockTimeout()
protected void parseRequestHeaders() throws WebDAVServerException
parseRequestHeaders
in class WebDAVMethod
WebDAVServerException
protected void parseRequestBody() throws WebDAVServerException
parseRequestBody
in class WebDAVMethod
WebDAVServerException
protected void executeImpl() throws WebDAVServerException, Exception
executeImpl
in class WebDAVMethod
WebDAVServerException
Exception
- any unhandled exceptionprotected void attemptLock() throws WebDAVServerException, Exception
WebDAVServerException
Exception
protected FileInfo createNode(org.alfresco.service.cmr.repository.NodeRef parentNodeRef, String name, org.alfresco.service.namespace.QName typeQName)
parentNodeRef
- the parent node.name
- the name of the nodetypeQName
- the type to createprotected final void createLock(FileInfo lockNode, String userName) throws WebDAVServerException
lockNode
- NodeRefuserName
- StringWebDAVServerException
protected final void refreshLock(FileInfo lockNode, String userName) throws WebDAVServerException
lockNode
- NodeRefuserName
- StringWebDAVServerException
protected void generateResponse(FileInfo lockNodeInfo, String userName) throws Exception
Exception
protected String generateNamespaceDeclarations(HashMap<String,String> nameSpaces)
generateNamespaceDeclarations
in class WebDAVMethod
Copyright © 2005–2017 Alfresco Software. All rights reserved.