com.solidstategroup.cms
Class DocumentAsset

java.lang.Object
  extended by com.solidstategroup.cms.Asset
      extended by com.solidstategroup.cms.DocumentAsset
All Implemented Interfaces:
com.solidstategroup.handles.Identifiable, com.solidstategroup.handles.Named, com.solidstategroup.handles.NamedIdentifiable, java.lang.Comparable
Direct Known Subclasses:
BinaryDocumentAsset

public class DocumentAsset
extends Asset


Field Summary
static int BINARY_DOCUMENT
           
static int[] DOCUMENT_TYPES
           
protected  int documentType
           
static int EXCEL_DOCUMENT
           
static int PDF_DOCUMENT
           
static int PLAINTEXT_DOCUMENT
           
static int WORD_DOCUMENT
           
 
Fields inherited from class com.solidstategroup.cms.Asset
createdOn, dublinCoreMetaData, includeInSearch, searchScore
 
Constructor Summary
DocumentAsset()
           
DocumentAsset(java.lang.String newURL)
           
DocumentAsset(java.lang.String newURL, int newAssetTypeId, int newAssetId, java.lang.String newDescription, java.lang.String newAssetFormat, int newAssetFormatId, int newChunkFormatId, java.lang.String description, int priority, boolean includeInSearch, int numberOfDownloads)
           
 
Method Summary
 boolean containsTag(int rootTagId)
           
 boolean delete()
           
 void execute()
           
 void executeTags()
           
 java.lang.String getAssetContents()
           
 java.lang.String getAssetData()
           
 java.lang.String getAssetDataPrefix()
           
 int getDocumentType()
           
 java.lang.String getFileExtension()
           
 DocumentAsset getHighestVersion()
           
 java.lang.String getLongDescription()
           
 int getMajorVersion()
           
 int getMinorVersion()
           
 int getNumberOfDownloads()
           
 java.lang.String getQuery()
           
 int getRootArticleTypeId()
           
 int getRootDocumentId()
           
 java.util.Vector getTags()
           
 java.lang.String getVersion()
           
 void incrementMajorVersion()
           
 void incrementMinorVersion()
           
 boolean isCurrentVersion()
           
 boolean isDocumentBeingUsed()
           
 void makeVersionCurrent()
           
 void setAssetData(java.lang.String assetData)
           
 void setAssetDataPrefix(java.lang.String assetDataPrefix)
           
 boolean setBinaryData(byte[] data)
           
 void setCurrentVersion(boolean currentVersion)
           
 void setDocumentType(int documentType)
           
 void setLongDescription(java.lang.String longDescription)
           
 void setMajorVersion(int majorVersion)
           
 void setMinorVersion(int minorVersion)
           
 void setNumberOfDownloads(int numberOfDownloads)
           
 void setRootArticleTypeId(int rootArticleTypeId)
           
 void setRootDocumentId(int rootDocumentId)
           
 void setTags(java.util.Vector tags)
           
 boolean storeNewAsset(int chunkId, java.sql.Connection conn)
           
 boolean storeNewAsset(java.lang.String fileLocation, java.sql.Connection conn)
           
 boolean update()
           
 boolean updateDescription()
           
 boolean updateDocumentURL()
           
 boolean updateLongDescription()
           
 boolean updateTags()
           
 
Methods inherited from class com.solidstategroup.cms.Asset
compareTo, destroy, getAssetDataUnprocessed, getAssetId, getAssetType, getChunkFormatId, getCreatedOn, getDescription, getDublinCoreMetaData, getId, getLastModified, getName, getRootArticleIds, getRootChunkFormatId, getSearchScore, isDeleted, isIncludeInSearch, setAssetId, setAssetType, setChunkFormatId, setCreatedOn, setDeleted, setDescription, setDublinCoreMetaData, setIncludeInSearch, setLastModified, setName, setRootChunkFormatId, storeAsset, storeBinaryAsset, storeUpdateAsset, storeUpdateAsset, validateLinks
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PLAINTEXT_DOCUMENT

public static final int PLAINTEXT_DOCUMENT
See Also:
Constant Field Values

BINARY_DOCUMENT

public static final int BINARY_DOCUMENT
See Also:
Constant Field Values

WORD_DOCUMENT

public static final int WORD_DOCUMENT
See Also:
Constant Field Values

PDF_DOCUMENT

public static final int PDF_DOCUMENT
See Also:
Constant Field Values

EXCEL_DOCUMENT

public static final int EXCEL_DOCUMENT
See Also:
Constant Field Values

DOCUMENT_TYPES

public static final int[] DOCUMENT_TYPES

documentType

protected int documentType
Constructor Detail

DocumentAsset

public DocumentAsset()

DocumentAsset

public DocumentAsset(java.lang.String newURL)

DocumentAsset

public DocumentAsset(java.lang.String newURL,
                     int newAssetTypeId,
                     int newAssetId,
                     java.lang.String newDescription,
                     java.lang.String newAssetFormat,
                     int newAssetFormatId,
                     int newChunkFormatId,
                     java.lang.String description,
                     int priority,
                     boolean includeInSearch,
                     int numberOfDownloads)
Method Detail

getQuery

public java.lang.String getQuery()

execute

public void execute()

executeTags

public void executeTags()

updateTags

public boolean updateTags()

storeNewAsset

public boolean storeNewAsset(java.lang.String fileLocation,
                             java.sql.Connection conn)
Overrides:
storeNewAsset in class Asset

storeNewAsset

public boolean storeNewAsset(int chunkId,
                             java.sql.Connection conn)
Overrides:
storeNewAsset in class Asset

updateDescription

public boolean updateDescription()

updateLongDescription

public boolean updateLongDescription()

updateDocumentURL

public boolean updateDocumentURL()

update

public boolean update()

isDocumentBeingUsed

public boolean isDocumentBeingUsed()

delete

public boolean delete()

makeVersionCurrent

public void makeVersionCurrent()

getFileExtension

public java.lang.String getFileExtension()

containsTag

public boolean containsTag(int rootTagId)

setBinaryData

public boolean setBinaryData(byte[] data)

setRootArticleTypeId

public void setRootArticleTypeId(int rootArticleTypeId)

getRootArticleTypeId

public int getRootArticleTypeId()

getAssetDataPrefix

public java.lang.String getAssetDataPrefix()

setAssetDataPrefix

public void setAssetDataPrefix(java.lang.String assetDataPrefix)

getAssetData

public java.lang.String getAssetData()
Overrides:
getAssetData in class Asset

setAssetData

public void setAssetData(java.lang.String assetData)
Overrides:
setAssetData in class Asset

getAssetContents

public java.lang.String getAssetContents()

getDocumentType

public int getDocumentType()

setDocumentType

public void setDocumentType(int documentType)

getNumberOfDownloads

public int getNumberOfDownloads()

setNumberOfDownloads

public void setNumberOfDownloads(int numberOfDownloads)

getMajorVersion

public int getMajorVersion()

setMajorVersion

public void setMajorVersion(int majorVersion)

getMinorVersion

public int getMinorVersion()

setMinorVersion

public void setMinorVersion(int minorVersion)

isCurrentVersion

public boolean isCurrentVersion()

setCurrentVersion

public void setCurrentVersion(boolean currentVersion)

getRootDocumentId

public int getRootDocumentId()

setRootDocumentId

public void setRootDocumentId(int rootDocumentId)

getVersion

public java.lang.String getVersion()

incrementMajorVersion

public void incrementMajorVersion()

incrementMinorVersion

public void incrementMinorVersion()

getHighestVersion

public DocumentAsset getHighestVersion()

getTags

public java.util.Vector getTags()

setTags

public void setTags(java.util.Vector tags)

getLongDescription

public java.lang.String getLongDescription()

setLongDescription

public void setLongDescription(java.lang.String longDescription)