eXo JCR :: Component :: Webdav Service 1.15.4-GA

org.exoplatform.services.jcr.webdav.resource
Class VersionResource

java.lang.Object
  extended by org.exoplatform.services.jcr.webdav.resource.GenericResource
      extended by org.exoplatform.services.jcr.webdav.resource.VersionResource
All Implemented Interfaces:
Resource, PropertyConstants

public class VersionResource
extends GenericResource

Created by The eXo Platform SARL .

Version:
$Id: $
Author:
Gennady Azarenkov

Field Summary
protected  javax.jcr.version.Version version
          resource version.
protected  VersionedResource versionedResource
          versioned resource.
 
Fields inherited from class org.exoplatform.services.jcr.webdav.resource.GenericResource
identifier, namespaceContext, PRESET_PROP, type
 
Fields inherited from interface org.exoplatform.services.jcr.webdav.resource.Resource
COLLECTION, FILE, NULL, VERSION, VERSION_HISTORY, VERSIONED_COLLECTION, VERSIONED_FILE
 
Fields inherited from interface org.exoplatform.services.jcr.webdav.util.PropertyConstants
CHILDCOUNT, CREATION_PATTERN, CREATIONDATE, DAV_ALLPROP, DAV_ALLPROP_INCLUDE, DISPLAYNAME, EXCLUSIVE, GETCONTENTLANGUAGE, GETCONTENTLENGTH, GETCONTENTTYPE, GETLASTMODIFIED, HASCHILDREN, IS_READ_ONLY, ISCOLLECTION, ISFOLDER, ISROOT, ISVERSIONED, JCR_CONTENT, JCR_DATA, LOCKDISCOVERY, LOCKSCOPE, LOCKTYPE, MODIFICATION_PATTERN, ORDERING_TYPE, OWNER, PARENTNAME, RESOURCETYPE, SUPPORTEDLOCK, SUPPORTEDMETHODSET, WRITE
 
Constructor Summary
VersionResource(URI identifier, VersionedResource versionedResource, javax.jcr.version.Version version, WebDavNamespaceContext namespaceContext)
           
 
Method Summary
 javax.jcr.Node contentNode()
          Returns content node.
 InputStream getContentAsStream()
          Returns the content of node as a stream.
 org.exoplatform.common.util.HierarchicalProperty getProperty(QName name)
          
 boolean isCollection()
          
 
Methods inherited from class org.exoplatform.services.jcr.webdav.resource.GenericResource
getIdentifier, getNamespaceContext, getProperties, getType, lockDiscovery, supportedLock, supportedMethodSet
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

version

protected final javax.jcr.version.Version version
resource version.


versionedResource

protected final VersionedResource versionedResource
versioned resource.

Constructor Detail

VersionResource

public VersionResource(URI identifier,
                       VersionedResource versionedResource,
                       javax.jcr.version.Version version,
                       WebDavNamespaceContext namespaceContext)
Parameters:
identifier - resource identifier
versionedResource - resource
version - version
namespaceContext - namespace context
Method Detail

getProperty

public org.exoplatform.common.util.HierarchicalProperty getProperty(QName name)
                                                             throws javax.jcr.PathNotFoundException,
                                                                    javax.jcr.AccessDeniedException,
                                                                    javax.jcr.RepositoryException

Parameters:
name - property name
Returns:
property by its name
Throws:
javax.jcr.PathNotFoundException - PathNotFoundException
javax.jcr.AccessDeniedException - AccessDeniedException
javax.jcr.RepositoryException - RepositoryException

isCollection

public final boolean isCollection()

Returns:
true if this is collection-able resource - i.e. this resource may contain other resources

contentNode

public javax.jcr.Node contentNode()
                           throws javax.jcr.RepositoryException
Returns content node.

Returns:
content node
Throws:
javax.jcr.RepositoryException - RepositoryException

getContentAsStream

public InputStream getContentAsStream()
                               throws javax.jcr.RepositoryException
Returns the content of node as a stream.

Returns:
content as stream
Throws:
javax.jcr.RepositoryException - RepositoryException

eXo JCR :: Component :: Webdav Service 1.15.4-GA

Copyright © 2013 eXo Platform SAS. All Rights Reserved.