com.solidstategroup.cms
Class Chunk

java.lang.Object
  extended by com.solidstategroup.cms.Chunk
All Implemented Interfaces:
com.solidstategroup.handles.Identifiable

public class Chunk
extends java.lang.Object
implements com.solidstategroup.handles.Identifiable


Field Summary
static int RENDER_TYPE_NORMAL
           
static int RENDER_TYPE_SEARCH
           
static int RENDER_TYPE_SUMMARY
           
 
Constructor Summary
Chunk()
           
Chunk(int newChunkId, java.lang.String newTitle, java.lang.String newChunkType, int newChunkTypeId, java.util.Date createdOn, java.util.Date lastModified, boolean newpublish, int newpriority, boolean pageBreak, boolean defaultChunk, int chunkNumber)
           
 
Method Summary
 boolean delete()
           
 boolean destroy()
           
 boolean destroyold()
          Deletes (permanently from the database) all assets and itself
 Assets execute()
           
 Assets execute(boolean isPreviewVersion)
           
 Assets execute(int articleId)
           
 Asset getAsset(java.lang.String description)
           
 java.lang.String getAssetData(java.lang.String thisAssetDescription)
           
 Assets getChunkAssets()
           
 int getChunkId()
           
 int getChunkNumber()
           
 ChunkType getChunkType()
           
 int getChunkTypeId()
           
 int getCountry_ID()
           
 Country getCountry()
           
 java.util.Date getCreatedDate()
           
 int getId()
           
 java.util.Date getLastModifiedDate()
           
 int getPriority()
           
 java.lang.String getQuery()
           
 int getRenderType()
           
 int getRootChunkTypeId()
           
 java.lang.String getTitle()
           
 boolean isDefaultChunk()
           
 boolean isDeleted()
           
 boolean isPageBreak()
           
 boolean isPublish()
           
 java.lang.String render(Article thisArticle)
           
 java.lang.String render(Article thisArticle, int sessionType, javax.servlet.http.HttpServletRequest request)
           
 java.lang.String render(java.lang.String imageURLPrefix, java.lang.String documentURLPrefix, Article thisArticle, int sessionType)
           
 java.lang.String renderPlainText(Article thisArticle, int numberOfCharactersToRender, int sessionType)
           
 void setChunkAssets(Assets chunkAssets)
           
 void setChunkId(int chunkId)
           
 void setChunkNumber(int chunkNumber)
           
 void setChunkType(ChunkType chunkType)
           
 void setChunkTypeId(int chunkTypeId)
           
 void setCountry_ID(int newCountryId)
           
 void setCountry(Country country)
           
 void setCreatedDate(java.util.Date createdDate)
           
 void setDefaultChunk(boolean defaultChunk)
           
 void setDeleted(boolean deleted)
           
 void setLastModifiedDate(java.util.Date lastModifiedDate)
           
 void setPageBreak(boolean pageBreak)
           
 void setPriority(int priority)
           
 void setPublish(boolean publish)
           
 void setRenderNormal()
           
 void setRenderSearch()
           
 void setRenderSummary()
           
 void setRenderType(int renderType)
           
 void setRootChunkTypeId(int rootChunkTypeId)
           
 void setTitle(java.lang.String thistitle)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RENDER_TYPE_NORMAL

public static final int RENDER_TYPE_NORMAL
See Also:
Constant Field Values

RENDER_TYPE_SUMMARY

public static final int RENDER_TYPE_SUMMARY
See Also:
Constant Field Values

RENDER_TYPE_SEARCH

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

Chunk

public Chunk()

Chunk

public Chunk(int newChunkId,
             java.lang.String newTitle,
             java.lang.String newChunkType,
             int newChunkTypeId,
             java.util.Date createdOn,
             java.util.Date lastModified,
             boolean newpublish,
             int newpriority,
             boolean pageBreak,
             boolean defaultChunk,
             int chunkNumber)
Method Detail

getQuery

public java.lang.String getQuery()

execute

public Assets execute(int articleId)

execute

public Assets execute(boolean isPreviewVersion)

execute

public Assets execute()

render

public java.lang.String render(Article thisArticle)

render

public java.lang.String render(Article thisArticle,
                               int sessionType,
                               javax.servlet.http.HttpServletRequest request)

renderPlainText

public java.lang.String renderPlainText(Article thisArticle,
                                        int numberOfCharactersToRender,
                                        int sessionType)

render

public java.lang.String render(java.lang.String imageURLPrefix,
                               java.lang.String documentURLPrefix,
                               Article thisArticle,
                               int sessionType)

delete

public boolean delete()

getAssetData

public java.lang.String getAssetData(java.lang.String thisAssetDescription)

destroyold

public boolean destroyold()
Deletes (permanently from the database) all assets and itself

Returns:
The outcome of the action

destroy

public boolean destroy()

setRenderNormal

public void setRenderNormal()

setRenderSummary

public void setRenderSummary()

setRenderSearch

public void setRenderSearch()

getAsset

public Asset getAsset(java.lang.String description)

getId

public int getId()
Specified by:
getId in interface com.solidstategroup.handles.Identifiable

getTitle

public java.lang.String getTitle()

setTitle

public void setTitle(java.lang.String thistitle)

setChunkAssets

public void setChunkAssets(Assets chunkAssets)

getChunkAssets

public Assets getChunkAssets()

setChunkId

public void setChunkId(int chunkId)

getChunkId

public int getChunkId()

setCreatedDate

public void setCreatedDate(java.util.Date createdDate)

getCreatedDate

public java.util.Date getCreatedDate()

setLastModifiedDate

public void setLastModifiedDate(java.util.Date lastModifiedDate)

getLastModifiedDate

public java.util.Date getLastModifiedDate()

setChunkTypeId

public void setChunkTypeId(int chunkTypeId)

getChunkTypeId

public int getChunkTypeId()

setRootChunkTypeId

public void setRootChunkTypeId(int rootChunkTypeId)

getRootChunkTypeId

public int getRootChunkTypeId()

setPublish

public void setPublish(boolean publish)

isPublish

public boolean isPublish()

setCountry_ID

public void setCountry_ID(int newCountryId)

getCountry_ID

public int getCountry_ID()

setCountry

public void setCountry(Country country)

getCountry

public Country getCountry()

setDeleted

public void setDeleted(boolean deleted)

isDeleted

public boolean isDeleted()

setPriority

public void setPriority(int priority)

getPriority

public int getPriority()

getChunkType

public ChunkType getChunkType()

setChunkType

public void setChunkType(ChunkType chunkType)

isDefaultChunk

public boolean isDefaultChunk()

setDefaultChunk

public void setDefaultChunk(boolean defaultChunk)

setPageBreak

public void setPageBreak(boolean pageBreak)

isPageBreak

public boolean isPageBreak()

getChunkNumber

public int getChunkNumber()

setChunkNumber

public void setChunkNumber(int chunkNumber)

getRenderType

public int getRenderType()

setRenderType

public void setRenderType(int renderType)