Interface NodeRepresentation
-
- All Known Implementing Classes:
AbstractXMLViewNodeRepresentation,DocumentViewNodeRepresentation,NtFileNodeRepresentation,NtResourceNodeRepresentation,SystemViewNodeRepresentation
public interface NodeRepresentationCreated by The eXo Platform SAS .- Version:
- $Id: $
- Author:
- Gennady Azarenkov
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidaddProperties(Collection<org.exoplatform.common.util.HierarchicalProperty> properties)adds multivalued property.voidaddProperty(org.exoplatform.common.util.HierarchicalProperty property)adds single property.StringgetContentEncoding()longgetContentLenght()InputStreamgetInputStream()longgetLastModified()Get date of last modified if available.StringgetMediaType()javax.jcr.NodegetNode()Collection<org.exoplatform.common.util.HierarchicalProperty>getProperties(String name)org.exoplatform.common.util.HierarchicalPropertygetProperty(String name)Collection<String>getPropertyNames()voidremoveProperty(String name)removes property.
-
-
-
Method Detail
-
getMediaType
String getMediaType() throws javax.jcr.RepositoryException
- Returns:
- Mimetype for this representation.
- Throws:
javax.jcr.RepositoryException
-
getContentLenght
long getContentLenght() throws javax.jcr.RepositoryException- Returns:
- the content length or -1 if content length unknown
- Throws:
javax.jcr.RepositoryException
-
getContentEncoding
String getContentEncoding()
- Returns:
- the content encoding or null if it unknown.
-
getInputStream
InputStream getInputStream() throws IOException, javax.jcr.RepositoryException
- Returns:
- the stream.
- Throws:
IOExceptionjavax.jcr.RepositoryException
-
getPropertyNames
Collection<String> getPropertyNames() throws javax.jcr.RepositoryException
- Returns:
- the collection of node properties name.
- Throws:
javax.jcr.RepositoryException
-
getProperty
org.exoplatform.common.util.HierarchicalProperty getProperty(String name) throws javax.jcr.RepositoryException
- Parameters:
name- the name of properties.- Returns:
- the property with specified name. Note that there can be multiple same name properties, in this case any one will be returned.
- Throws:
javax.jcr.RepositoryException
-
getProperties
Collection<org.exoplatform.common.util.HierarchicalProperty> getProperties(String name) throws javax.jcr.RepositoryException
- Parameters:
name- the name of properties.- Returns:
- the properties with specified name.
- Throws:
javax.jcr.RepositoryException
-
addProperty
void addProperty(org.exoplatform.common.util.HierarchicalProperty property) throws javax.jcr.UnsupportedRepositoryOperationExceptionadds single property.- Parameters:
property- .- Throws:
javax.jcr.UnsupportedRepositoryOperationException
-
addProperties
void addProperties(Collection<org.exoplatform.common.util.HierarchicalProperty> properties) throws javax.jcr.UnsupportedRepositoryOperationException
adds multivalued property.- Parameters:
properties- .- Throws:
javax.jcr.UnsupportedRepositoryOperationException
-
removeProperty
void removeProperty(String name) throws javax.jcr.UnsupportedRepositoryOperationException
removes property.- Parameters:
name- .- Throws:
javax.jcr.UnsupportedRepositoryOperationException
-
getLastModified
long getLastModified() throws javax.jcr.RepositoryExceptionGet date of last modified if available.- Returns:
- the date of last modified.
- Throws:
javax.jcr.RepositoryException
-
getNode
javax.jcr.Node getNode()
- Returns:
- the underlying node.
-
-