com.adobe.repository.infomodel.bean
Class ResourceContent

java.lang.Object
  extended by com.adobe.repository.infomodel.bean.ResourceContent
All Implemented Interfaces:
java.io.Serializable

public class ResourceContent
extends java.lang.Object
implements java.io.Serializable

The Repository's representation of file data. The data can be stored within the Repository or it can also be linked externally through a reference to a URI. External content is not managed by the Repository, and in such cases the size and checksum attributes will be set to zero or null.

See Also:
Serialized Form

Field Summary
static int ATTRIBUTE_CONTENT_URI
           
static int ATTRIBUTE_DATA
           
static int ATTRIBUTE_MIME_TYPE
           
static int ATTRIBUTE_SIZE
           
static int OBJECT_TYPE_RESOURCE_CONTENT
          Contains the object type value which represents ResourceContent instances.
 
Constructor Summary
ResourceContent()
          Default constructor.
 
Method Summary
 java.lang.String getContentUri()
          Retrieves the URI that points to the location of the external content.
 java.util.Date getCreateTime()
          Retrieves the time at which this resource content was first written to the Repository.
 Document getDataDocument()
          Retrieves a Document representation of the bytes stored in the data.
 java.lang.String getMimeType()
          Retrieves the MIME type of the data.
 long getOid()
          Retrieves this object's numerical identifier.
 int getSize()
          Retrieves the byte count of the data.
 java.util.Date getUpdateTime()
          Retrieves the time at which this resource content was last modified.
 boolean isProjected(int attribute)
          Determines whether the supplied attribute or composed object is projected.
 void setContentUri(java.lang.String contentUri)
          Sets the URI that points to the location of external content.
 void setCreateTime(java.util.Date createTime)
          Sets the time at which this resource content was first written to the Repository.
 void setDataDocument(Document dataDocument)
          Sets the byte source for this ResourceContent's data.
 void setMimeType(java.lang.String mimeType)
          Sets the MIME type of the data.
 void setOid(long oid)
          Sets this object's numerical identifier.
 void setRepositoryLoadProfile(RepositoryLoadProfile loadProfile)
          Sets the Repository load profile for this resource content.
 void setSize(int size)
          Sets the byte count of the data.
 void setUpdateTime(java.util.Date updateTime)
          Sets the time at which this resource content was last modified.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

OBJECT_TYPE_RESOURCE_CONTENT

public static final int OBJECT_TYPE_RESOURCE_CONTENT
Contains the object type value which represents ResourceContent instances.

See Also:
Constant Field Values

ATTRIBUTE_DATA

public static final int ATTRIBUTE_DATA
See Also:
Constant Field Values

ATTRIBUTE_MIME_TYPE

public static final int ATTRIBUTE_MIME_TYPE
See Also:
Constant Field Values

ATTRIBUTE_SIZE

public static final int ATTRIBUTE_SIZE
See Also:
Constant Field Values

ATTRIBUTE_CONTENT_URI

public static final int ATTRIBUTE_CONTENT_URI
See Also:
Constant Field Values
Constructor Detail

ResourceContent

public ResourceContent()
Default constructor.

Method Detail

setRepositoryLoadProfile

public void setRepositoryLoadProfile(RepositoryLoadProfile loadProfile)
Sets the Repository load profile for this resource content. The load profile which defines the object types and attributes to be returned from (projected in) a Repository query. For more information, see RepositoryLoadProfile.

Parameters:
loadProfile - The Repository load profile for this resource content.

isProjected

public boolean isProjected(int attribute)
Determines whether the supplied attribute or composed object is projected.

Parameters:
attribute - Any one of the LOAD_* constants.
Returns:
true if the supplied attribute or composed object is projected, false otherwise.

getOid

public long getOid()
Retrieves this object's numerical identifier.

Returns:
This object's numerical identifier.

setOid

public void setOid(long oid)
Sets this object's numerical identifier.

Parameters:
oid - This object's numerical identifier.

getDataDocument

public Document getDataDocument()
Retrieves a Document representation of the bytes stored in the data.

Returns:
A Document representation of the bytes stored in the data.

setDataDocument

public void setDataDocument(Document dataDocument)
Sets the byte source for this ResourceContent's data. The data will be read when the containing Resource is written to the Repository.

Parameters:
dataDocument - A valid Document instance containing the byte source for the data.

getMimeType

public java.lang.String getMimeType()
Retrieves the MIME type of the data.

Returns:
The MIME type of the data.

setMimeType

public void setMimeType(java.lang.String mimeType)
Sets the MIME type of the data.

Parameters:
mimeType - A String indicating the MIME type of the data.

getSize

public int getSize()
Retrieves the byte count of the data.

Returns:
The byte count of the data.

setSize

public void setSize(int size)
Sets the byte count of the data.

Parameters:
size - A non-negative, integer value representing the byte count of the data.

getContentUri

public java.lang.String getContentUri()
Retrieves the URI that points to the location of the external content.

Returns:
A URI that points to the location of the external content.

setContentUri

public void setContentUri(java.lang.String contentUri)
Sets the URI that points to the location of external content.

Parameters:
contentUri - the URI that points to the location of external content.

getUpdateTime

public java.util.Date getUpdateTime()
Retrieves the time at which this resource content was last modified.

Returns:
The time at which this resource content was last modified.

setUpdateTime

public void setUpdateTime(java.util.Date updateTime)
Sets the time at which this resource content was last modified.

Parameters:
updateTime - The time at which this resource content was last modified.

getCreateTime

public java.util.Date getCreateTime()
Retrieves the time at which this resource content was first written to the Repository.

Returns:
The time at which this resource content was first written to the Repository.

setCreateTime

public void setCreateTime(java.util.Date createTime)
Sets the time at which this resource content was first written to the Repository.

Parameters:
createTime - The time at which this resource content was first written to the Repository.


[an error occurred while processing this directive] [an error occurred while processing this directive]