public class DavResourceImpl extends Object implements org.apache.jackrabbit.webdav.DavResource, org.apache.jackrabbit.webdav.bind.BindableResource, org.apache.jackrabbit.JcrConstants
| Modifier and Type | Field and Description |
|---|---|
static String |
COMPLIANCE_CLASSES |
static String |
METHODS |
protected org.apache.jackrabbit.webdav.property.DavPropertySet |
properties |
protected boolean |
propsInitialized |
JCR_AUTOCREATED, JCR_BASEVERSION, JCR_CHILD, JCR_CHILDNODEDEFINITION, JCR_CONTENT, JCR_CREATED, JCR_DATA, JCR_DEFAULTPRIMARYTYPE, JCR_DEFAULTVALUES, JCR_ENCODING, JCR_FROZENMIXINTYPES, JCR_FROZENNODE, JCR_FROZENPRIMARYTYPE, JCR_FROZENUUID, JCR_HASORDERABLECHILDNODES, JCR_ISCHECKEDOUT, JCR_ISMIXIN, JCR_LANGUAGE, JCR_LASTMODIFIED, JCR_LOCKISDEEP, JCR_LOCKOWNER, JCR_MANDATORY, JCR_MERGEFAILED, JCR_MIMETYPE, JCR_MIXINTYPES, JCR_MULTIPLE, JCR_NAME, JCR_NODETYPENAME, JCR_ONPARENTVERSION, JCR_PATH, JCR_PREDECESSORS, JCR_PRIMARYITEMNAME, JCR_PRIMARYTYPE, JCR_PROPERTYDEFINITION, JCR_PROTECTED, JCR_REQUIREDPRIMARYTYPES, JCR_REQUIREDTYPE, JCR_ROOTVERSION, JCR_SAMENAMESIBLINGS, JCR_SCORE, JCR_STATEMENT, JCR_SUCCESSORS, JCR_SUPERTYPES, JCR_SYSTEM, JCR_UUID, JCR_VALUECONSTRAINTS, JCR_VERSIONABLEUUID, JCR_VERSIONHISTORY, JCR_VERSIONLABELS, JCR_VERSIONSTORAGE, MIX_LOCKABLE, MIX_REFERENCEABLE, MIX_SHAREABLE, MIX_VERSIONABLE, NT_BASE, NT_CHILDNODEDEFINITION, NT_FILE, NT_FOLDER, NT_FROZENNODE, NT_HIERARCHYNODE, NT_LINKEDFILE, NT_NODETYPE, NT_PROPERTYDEFINITION, NT_QUERY, NT_RESOURCE, NT_UNSTRUCTURED, NT_VERSION, NT_VERSIONEDCHILD, NT_VERSIONHISTORY, NT_VERSIONLABELS| Constructor and Description |
|---|
DavResourceImpl(org.apache.jackrabbit.webdav.DavResourceLocator locator,
org.apache.jackrabbit.webdav.DavResourceFactory factory,
org.apache.jackrabbit.webdav.DavSession session,
ResourceConfig config,
boolean isCollection)
Create a new
DavResource. |
DavResourceImpl(org.apache.jackrabbit.webdav.DavResourceLocator locator,
org.apache.jackrabbit.webdav.DavResourceFactory factory,
org.apache.jackrabbit.webdav.DavSession session,
ResourceConfig config,
Node node)
Create a new
DavResource. |
| Modifier and Type | Method and Description |
|---|---|
void |
addLockManager(org.apache.jackrabbit.webdav.lock.LockManager lockMgr) |
void |
addMember(org.apache.jackrabbit.webdav.DavResource member,
org.apache.jackrabbit.webdav.io.InputContext inputContext)
Adds a new member to this resource.
|
org.apache.jackrabbit.webdav.MultiStatusResponse |
alterProperties(List<? extends org.apache.jackrabbit.webdav.property.PropEntry> changeList) |
void |
bind(org.apache.jackrabbit.webdav.DavResource collection,
org.apache.jackrabbit.webdav.DavResource newBinding) |
void |
copy(org.apache.jackrabbit.webdav.DavResource destination,
boolean shallow) |
boolean |
exists() |
org.apache.jackrabbit.webdav.DavResource |
getCollection() |
String |
getComplianceClass() |
String |
getDisplayName()
Returns the the last segment of the resource path.
|
protected ExportContext |
getExportContext(org.apache.jackrabbit.webdav.io.OutputContext outputCtx)
Returns a new
ExportContext |
org.apache.jackrabbit.webdav.DavResourceFactory |
getFactory() |
String |
getHref() |
protected ImportContext |
getImportContext(org.apache.jackrabbit.webdav.io.InputContext inputCtx,
String systemId)
Returns a new
ImportContext |
org.apache.jackrabbit.webdav.DavResourceLocator |
getLocator() |
org.apache.jackrabbit.webdav.lock.ActiveLock |
getLock(org.apache.jackrabbit.webdav.lock.Type type,
org.apache.jackrabbit.webdav.lock.Scope scope) |
org.apache.jackrabbit.webdav.lock.ActiveLock[] |
getLocks() |
org.apache.jackrabbit.webdav.DavResourceIterator |
getMembers() |
long |
getModificationTime() |
protected Node |
getNode()
Returns the node that is wrapped by this resource.
|
Set<org.apache.jackrabbit.webdav.bind.ParentElement> |
getParentElements() |
org.apache.jackrabbit.webdav.property.DavPropertySet |
getProperties() |
org.apache.jackrabbit.webdav.property.DavProperty<?> |
getProperty(org.apache.jackrabbit.webdav.property.DavPropertyName name) |
protected PropertyExportContext |
getPropertyExportContext()
Returns a new
PropertyExportContext. |
protected PropertyImportContext |
getPropertyImportContext(List<? extends org.apache.jackrabbit.webdav.property.PropEntry> changeList)
Returns a new
PropertyImportContext. |
org.apache.jackrabbit.webdav.property.DavPropertyName[] |
getPropertyNames() |
String |
getResourcePath() |
org.apache.jackrabbit.webdav.DavSession |
getSession() |
String |
getSupportedMethods() |
boolean |
hasLock(org.apache.jackrabbit.webdav.lock.Type type,
org.apache.jackrabbit.webdav.lock.Scope scope) |
protected void |
initProperties()
Fill the set of properties
|
boolean |
isCollection() |
boolean |
isLockable(org.apache.jackrabbit.webdav.lock.Type type,
org.apache.jackrabbit.webdav.lock.Scope scope) |
org.apache.jackrabbit.webdav.lock.ActiveLock |
lock(org.apache.jackrabbit.webdav.lock.LockInfo lockInfo) |
void |
move(org.apache.jackrabbit.webdav.DavResource destination) |
void |
rebind(org.apache.jackrabbit.webdav.DavResource collection,
org.apache.jackrabbit.webdav.DavResource newBinding) |
org.apache.jackrabbit.webdav.lock.ActiveLock |
refreshLock(org.apache.jackrabbit.webdav.lock.LockInfo lockInfo,
String lockToken) |
void |
removeMember(org.apache.jackrabbit.webdav.DavResource member) |
void |
removeProperty(org.apache.jackrabbit.webdav.property.DavPropertyName propertyName) |
void |
setProperty(org.apache.jackrabbit.webdav.property.DavProperty<?> property) |
void |
spool(org.apache.jackrabbit.webdav.io.OutputContext outputContext)
If this resource exists and the specified context is not
null
this implementation build a new ExportContext based on the specified
context and forwards the export to its IOManager. |
void |
unlock(String lockToken) |
public static final String METHODS
public static final String COMPLIANCE_CLASSES
protected org.apache.jackrabbit.webdav.property.DavPropertySet properties
protected boolean propsInitialized
public DavResourceImpl(org.apache.jackrabbit.webdav.DavResourceLocator locator,
org.apache.jackrabbit.webdav.DavResourceFactory factory,
org.apache.jackrabbit.webdav.DavSession session,
ResourceConfig config,
boolean isCollection)
throws org.apache.jackrabbit.webdav.DavException
DavResource.locator - factory - session - config - isCollection - org.apache.jackrabbit.webdav.DavExceptionpublic DavResourceImpl(org.apache.jackrabbit.webdav.DavResourceLocator locator,
org.apache.jackrabbit.webdav.DavResourceFactory factory,
org.apache.jackrabbit.webdav.DavSession session,
ResourceConfig config,
Node node)
throws org.apache.jackrabbit.webdav.DavException
DavResource.locator - factory - session - config - node - org.apache.jackrabbit.webdav.DavExceptionpublic String getComplianceClass()
getComplianceClass in interface org.apache.jackrabbit.webdav.DavResourceDavResource.getComplianceClass()public String getSupportedMethods()
getSupportedMethods in interface org.apache.jackrabbit.webdav.DavResourceDavResource.getSupportedMethods()public boolean exists()
exists in interface org.apache.jackrabbit.webdav.DavResource)public boolean isCollection()
isCollection in interface org.apache.jackrabbit.webdav.DavResourceDavResource.isCollection()public org.apache.jackrabbit.webdav.DavResourceLocator getLocator()
getLocator in interface org.apache.jackrabbit.webdav.DavResourceDavResource.getLocator()public String getResourcePath()
getResourcePath in interface org.apache.jackrabbit.webdav.DavResourceDavResource.getResourcePath()public String getHref()
getHref in interface org.apache.jackrabbit.webdav.DavResourceDavResource.getHref()public String getDisplayName()
Note that this must not correspond to the name of the underlying repository item for two reasons:
getDisplayName in interface org.apache.jackrabbit.webdav.DavResourceDavResource.getDisplayName()public long getModificationTime()
getModificationTime in interface org.apache.jackrabbit.webdav.DavResourceDavResource.getModificationTime()public void spool(org.apache.jackrabbit.webdav.io.OutputContext outputContext)
throws IOException
null
this implementation build a new ExportContext based on the specified
context and forwards the export to its IOManager. If the
IOManager.exportContent(ExportContext, DavResource) fails,
an IOException is thrown.spool in interface org.apache.jackrabbit.webdav.DavResourceIOException - if the export fails.DavResource.spool(OutputContext),
ResourceConfig.getIOManager()public org.apache.jackrabbit.webdav.property.DavProperty<?> getProperty(org.apache.jackrabbit.webdav.property.DavPropertyName name)
getProperty in interface org.apache.jackrabbit.webdav.DavResourceDavResource.getProperty(org.apache.jackrabbit.webdav.property.DavPropertyName)public org.apache.jackrabbit.webdav.property.DavPropertySet getProperties()
getProperties in interface org.apache.jackrabbit.webdav.DavResourceDavResource.getProperties()public org.apache.jackrabbit.webdav.property.DavPropertyName[] getPropertyNames()
getPropertyNames in interface org.apache.jackrabbit.webdav.DavResourceDavResource.getPropertyNames()protected void initProperties()
public void setProperty(org.apache.jackrabbit.webdav.property.DavProperty<?> property)
throws org.apache.jackrabbit.webdav.DavException
setProperty in interface org.apache.jackrabbit.webdav.DavResourceproperty - org.apache.jackrabbit.webdav.DavExceptionDavResource.setProperty(org.apache.jackrabbit.webdav.property.DavProperty)public void removeProperty(org.apache.jackrabbit.webdav.property.DavPropertyName propertyName)
throws org.apache.jackrabbit.webdav.DavException
removeProperty in interface org.apache.jackrabbit.webdav.DavResourcepropertyName - org.apache.jackrabbit.webdav.DavExceptionDavResource.removeProperty(org.apache.jackrabbit.webdav.property.DavPropertyName)public org.apache.jackrabbit.webdav.MultiStatusResponse alterProperties(List<? extends org.apache.jackrabbit.webdav.property.PropEntry> changeList) throws org.apache.jackrabbit.webdav.DavException
alterProperties in interface org.apache.jackrabbit.webdav.DavResourceorg.apache.jackrabbit.webdav.DavExceptionpublic org.apache.jackrabbit.webdav.DavResource getCollection()
getCollection in interface org.apache.jackrabbit.webdav.DavResourceDavResource.getCollection()public org.apache.jackrabbit.webdav.DavResourceIterator getMembers()
getMembers in interface org.apache.jackrabbit.webdav.DavResourceDavResource.getMembers()public void addMember(org.apache.jackrabbit.webdav.DavResource member,
org.apache.jackrabbit.webdav.io.InputContext inputContext)
throws org.apache.jackrabbit.webdav.DavException
addMember in interface org.apache.jackrabbit.webdav.DavResourceorg.apache.jackrabbit.webdav.DavExceptionDavResource.addMember(DavResource, org.apache.jackrabbit.webdav.io.InputContext)public void removeMember(org.apache.jackrabbit.webdav.DavResource member)
throws org.apache.jackrabbit.webdav.DavException
removeMember in interface org.apache.jackrabbit.webdav.DavResourceorg.apache.jackrabbit.webdav.DavExceptionDavResource.removeMember(DavResource)public void move(org.apache.jackrabbit.webdav.DavResource destination)
throws org.apache.jackrabbit.webdav.DavException
move in interface org.apache.jackrabbit.webdav.DavResourceorg.apache.jackrabbit.webdav.DavExceptionDavResource.move(DavResource)public void copy(org.apache.jackrabbit.webdav.DavResource destination,
boolean shallow)
throws org.apache.jackrabbit.webdav.DavException
copy in interface org.apache.jackrabbit.webdav.DavResourceorg.apache.jackrabbit.webdav.DavExceptionDavResource.copy(DavResource, boolean)public boolean isLockable(org.apache.jackrabbit.webdav.lock.Type type,
org.apache.jackrabbit.webdav.lock.Scope scope)
isLockable in interface org.apache.jackrabbit.webdav.DavResourcetype - scope - Type.WRITE and scope is Scope.EXCLUSIVEDavResource.isLockable(org.apache.jackrabbit.webdav.lock.Type, org.apache.jackrabbit.webdav.lock.Scope)public boolean hasLock(org.apache.jackrabbit.webdav.lock.Type type,
org.apache.jackrabbit.webdav.lock.Scope scope)
hasLock in interface org.apache.jackrabbit.webdav.DavResourceDavResource.hasLock(org.apache.jackrabbit.webdav.lock.Type, org.apache.jackrabbit.webdav.lock.Scope)public org.apache.jackrabbit.webdav.lock.ActiveLock getLock(org.apache.jackrabbit.webdav.lock.Type type,
org.apache.jackrabbit.webdav.lock.Scope scope)
getLock in interface org.apache.jackrabbit.webdav.DavResourceDavResource.getLock(Type, Scope)public org.apache.jackrabbit.webdav.lock.ActiveLock[] getLocks()
getLocks in interface org.apache.jackrabbit.webdav.DavResourceDavResource.getLocks()public org.apache.jackrabbit.webdav.lock.ActiveLock lock(org.apache.jackrabbit.webdav.lock.LockInfo lockInfo)
throws org.apache.jackrabbit.webdav.DavException
lock in interface org.apache.jackrabbit.webdav.DavResourceorg.apache.jackrabbit.webdav.DavExceptionDavResource.lock(LockInfo)public org.apache.jackrabbit.webdav.lock.ActiveLock refreshLock(org.apache.jackrabbit.webdav.lock.LockInfo lockInfo,
String lockToken)
throws org.apache.jackrabbit.webdav.DavException
refreshLock in interface org.apache.jackrabbit.webdav.DavResourceorg.apache.jackrabbit.webdav.DavExceptionDavResource.refreshLock(LockInfo, String)public void unlock(String lockToken) throws org.apache.jackrabbit.webdav.DavException
unlock in interface org.apache.jackrabbit.webdav.DavResourceorg.apache.jackrabbit.webdav.DavExceptionDavResource.unlock(String)public void addLockManager(org.apache.jackrabbit.webdav.lock.LockManager lockMgr)
addLockManager in interface org.apache.jackrabbit.webdav.DavResourceDavResource.addLockManager(org.apache.jackrabbit.webdav.lock.LockManager)public org.apache.jackrabbit.webdav.DavResourceFactory getFactory()
getFactory in interface org.apache.jackrabbit.webdav.DavResourceDavResource.getFactory()public org.apache.jackrabbit.webdav.DavSession getSession()
getSession in interface org.apache.jackrabbit.webdav.DavResourceDavResource.getSession()public void bind(org.apache.jackrabbit.webdav.DavResource collection,
org.apache.jackrabbit.webdav.DavResource newBinding)
throws org.apache.jackrabbit.webdav.DavException
bind in interface org.apache.jackrabbit.webdav.bind.BindableResourceorg.apache.jackrabbit.webdav.DavExceptionBindableResource.rebind(DavResource, DavResource)public void rebind(org.apache.jackrabbit.webdav.DavResource collection,
org.apache.jackrabbit.webdav.DavResource newBinding)
throws org.apache.jackrabbit.webdav.DavException
rebind in interface org.apache.jackrabbit.webdav.bind.BindableResourceorg.apache.jackrabbit.webdav.DavExceptionBindableResource.rebind(DavResource, DavResource)public Set<org.apache.jackrabbit.webdav.bind.ParentElement> getParentElements()
getParentElements in interface org.apache.jackrabbit.webdav.bind.BindableResourceBindableResource.getParentElements()protected Node getNode()
protected ImportContext getImportContext(org.apache.jackrabbit.webdav.io.InputContext inputCtx, String systemId) throws IOException
ImportContextinputCtx - systemId - ImportContextIOExceptionprotected ExportContext getExportContext(org.apache.jackrabbit.webdav.io.OutputContext outputCtx) throws IOException
ExportContextoutputCtx - ExportContextIOExceptionprotected PropertyImportContext getPropertyImportContext(List<? extends org.apache.jackrabbit.webdav.property.PropEntry> changeList)
PropertyImportContext.changeList - PropertyImportContext.protected PropertyExportContext getPropertyExportContext()
PropertyExportContext.PropertyExportContextCopyright © 2004-2014 The Apache Software Foundation. All Rights Reserved.