@Deprecated public class JCRResource extends Object implements ModifiableResource
| Modifier and Type | Field and Description |
|---|---|
private boolean |
_lockAlreadyChecked
Deprecated.
|
private Node |
_node
Deprecated.
|
| Constructor and Description |
|---|
JCRResource(Node node)
Deprecated.
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
_checkLock()
Deprecated.
Check if the node is locked
|
String |
getEncoding()
Deprecated.
Returns the encoding if the data stream, if it is a character stream.
|
InputStream |
getInputStream()
Deprecated.
Returns the data stream.
|
Date |
getLastModified()
Deprecated.
Returns the last modification date.
|
long |
getLength()
Deprecated.
Returns the length of the data stream.
|
String |
getMimeType()
Deprecated.
Returns the data mime-type.
|
Node |
getNode()
Deprecated.
Retrieves the underlying node.
|
OutputStream |
getOutputStream()
Deprecated.
Returns an OuputStream to write the data stream.
|
void |
rename(String newName)
Deprecated.
Rename the current metadata
|
void |
setEncoding(String encoding)
Deprecated.
Set the encoding if the data stream, if it is a character stream.
|
void |
setInputStream(InputStream stream)
Deprecated.
Set the data stream.
|
void |
setLastModified(Date lastModifiedDate)
Deprecated.
Set the last modification date.
|
void |
setMimeType(String mimeType)
Deprecated.
Set the mime type.
|
private boolean _lockAlreadyChecked
public JCRResource(Node node)
node - the nt:resource Nodepublic Node getNode()
public void rename(String newName) throws AmetysRepositoryException
ModifiableResourcerename in interface ModifiableResourcenewName - the new nameAmetysRepositoryException - if an error occurs.public String getEncoding() throws AmetysRepositoryException
ResourcegetEncoding in interface Resourcenull if not available.AmetysRepositoryException - if an error occurs.public InputStream getInputStream() throws AmetysRepositoryException
ResourcegetInputStream in interface ResourceAmetysRepositoryException - if an error occurs.public Date getLastModified() throws AmetysRepositoryException
ResourcegetLastModified in interface ResourceAmetysRepositoryException - if an error occurs.public long getLength() throws AmetysRepositoryException
ResourcegetLength in interface ResourceAmetysRepositoryException - if an error occurs.public String getMimeType() throws AmetysRepositoryException
ResourcegetMimeType in interface ResourceAmetysRepositoryException - if an error occurs.public void setEncoding(String encoding) throws AmetysRepositoryException
ModifiableResourcesetEncoding in interface ModifiableResourceencoding - the encoding of the data stream.AmetysRepositoryException - if an error occurs.public void setInputStream(InputStream stream) throws AmetysRepositoryException
ModifiableResourcesetInputStream in interface ModifiableResourcestream - the data stream.AmetysRepositoryException - if an error occurs.public void setLastModified(Date lastModifiedDate) throws AmetysRepositoryException
ModifiableResourcesetLastModified in interface ModifiableResourcelastModifiedDate - the last modification date.AmetysRepositoryException - if an error occurs.public void setMimeType(String mimeType) throws AmetysRepositoryException
ModifiableResourcesetMimeType in interface ModifiableResourcemimeType - the mime type of the data.AmetysRepositoryException - if an error occurs.public OutputStream getOutputStream() throws AmetysRepositoryException
ModifiableResourcegetOutputStream in interface ModifiableResourceAmetysRepositoryException - if an error occurs.protected void _checkLock() throws RepositoryException
RepositoryException - if an error occurred