com.jalios.jcms.portlet
Class PortalElement

java.lang.Object
  extended by com.jalios.jstore.BasicStorable
      extended by com.jalios.jcms.Data
          extended by com.jalios.jcms.Publication
              extended by com.jalios.jcms.portlet.PortalElement
All Implemented Interfaces:
EditableData, JcmsConstants, ImportConstants, MashupConstants, Searchable, Storable, JaliosConstants, TreeNode, Cloneable, Comparable<BasicStorable>
Direct Known Subclasses:
Portal, PortalRedirect, Portlet

public abstract class PortalElement
extends Publication
implements TreeNode


Nested Class Summary
static class PortalElement.AbilitySelector
          AbilitySelector selects all the publications with the given ability
 
Nested classes/interfaces inherited from class com.jalios.jcms.Publication
Publication.AdateComparator<T extends Publication>, Publication.AdateSelector, Publication.AudienceRightComparator<T extends Publication>, Publication.AudienceRightSelector, Publication.AuthorComparator<T extends Publication>, Publication.AuthorizedSelector, Publication.CanWorkOnSelector, Publication.DdateComparator<T extends Publication>, Publication.EdateComparator<T extends Publication>, Publication.EdateSelector, Publication.PdateComparator<T extends Publication>, Publication.PdateSelector, Publication.PstatusComparator<T extends Publication>, Publication.PstatusSelector, Publication.RatingComparator<T extends Publication>, Publication.ReaderComparator<T extends Publication>, Publication.ReadRightSelector, Publication.ReviewCountComparator<T extends Publication>, Publication.RightComparator<T extends Publication>, Publication.SdateComparator<T extends Publication>, Publication.SdateSelector, Publication.TitleComparator<T extends Publication>, Publication.TrackedSelector, Publication.TypeComparator<T extends Publication>, Publication.UdateComparator<T extends Publication>, Publication.UdateSelector, Publication.UserContentSelector, Publication.VisibleStateSelector, Publication.WorkspaceAuthorSelector, Publication.WorkspaceComparator<T extends Publication>, Publication.WorkspaceSelector
 
Nested classes/interfaces inherited from class com.jalios.jcms.Data
Data.AuthorSelector, Data.CdateSelector, Data.DataNameComparator<T extends Data>, Data.DeletableSelector, Data.ImportSelector, Data.MdateSelector, Data.OpAuthorComparator<T extends Data>
 
Nested classes/interfaces inherited from class com.jalios.jstore.BasicStorable
BasicStorable.CdateComparator<T extends Storable>, BasicStorable.IdComparator<T extends Storable>, BasicStorable.MdateComparator<T extends Storable>
 
Field Summary
protected  String[] abilities
           
protected static String[] allAbilities
           
protected static Map allAbilityMap
           
protected  List cachedAbilities
           
static String ICON_PORTLET
           
static String ICON_STATS
           
static String REVISION
           
protected static TypeTemplateEntry tteDefault
           
 
Fields inherited from class com.jalios.jcms.Publication
adate, authorizedGroupSet, authorizedMemberSet, categories, categorySet, CTRL_TOPIC_ADVANCED, CTRL_TOPIC_CATEGORIES, CTRL_TOPIC_WORKFLOW, edate, friendlyURLSet, indexMgr, isTracked, mainInstance, mainLanguage, majorVersion, mergeDate, mergeId, minorVersion, pdate, pstatus, roleMap, sdate, templates, title, titleML, udate, updateGroupSet, updateMemberSet, wfExpressAlarmEntry, wfReminderAlarmEntry, workspace
 
Fields inherited from class com.jalios.jcms.Data
author, authorDBID, channel, DISPLAY_URL_EXTRA_INFO, extension, extraDataMap, extraDBDataMapToSaveOnOp, importMap, lockDate, lockMember, opAuthor, opDelegate
 
Fields inherited from class com.jalios.jstore.BasicStorable
cdate, ddate, id, mdate, store
 
Fields inherited from interface com.jalios.jcms.mashup.ImportConstants
IMPORT_ALARM_MGR, IMPORT_AUTHOR_PROP, IMPORT_CATEGORY_DEFAULT, IMPORT_DC_ATTR, IMPORT_DC_STEP, IMPORT_DIR, IMPORT_ENABLED, IMPORT_JDOM_ELEMENT, IMPORT_LOG_FILE, IMPORT_LOG_MAX, IMPORT_OPTIONS, IMPORT_OPTIONS_DC_CONTEXT, IMPORT_ROOT_PROP, IMPORT_SOURCE_FILE, IMPORT_SOURCE_PREFIX_PROP, IMPORT_SOURCES_DIR, IMPORT_STEP_CLEAN, IMPORT_STEP_IMPORT, IMPORT_STEP_UPDATE_REF, IMPORT_WS_PROP
 
Fields inherited from interface com.jalios.jcms.mashup.MashupConstants
DATA_TAG, DATASET_TAG, FIELD_CLASS, FIELD_ENTRY, FIELD_ITEM, FIELD_KEY, FIELD_NAME, FIELD_TAG, FIELD_VALUE, FILE_FIELD, FILE_ID, FILE_MTIME, FILE_SIZE, FILE_TAG, FILE_TICKET, FILESET_TAG, RELATED_TAG
 
Fields inherited from interface com.jalios.jcms.JcmsConstants
ADATE_SEARCH, ADMIN_NOTES_PROP, ADVANCED_TAB, ARCHIVES_DIR, ASCII_WIDTH, CATEGORY_TAB, CDATE_SEARCH, COMMON_ALARM, CONTENT_TAB, COOKIE_MAX_AGE, CRYPT_MD5, CRYPT_UNDEFINED, CRYPT_UNIX, CTRL_TOPIC_INTERNAL, CTRL_TOPIC_REF, CTRL_TOPIC_VALUE, CTRL_TOPIC_WRITE, CUSTOM_PROP, DOCCHOOSER_HEIGHT, DOCCHOOSER_WIDTH, DOCS_DIR, EDATE_SEARCH, EMAIL_REGEXP, ERROR_MSG, FORBIDDEN_FILE_ACCESS, FORBIDDEN_REDIRECT, FORCE_REDIRECT, ICON_ARCHIVE, ICON_LOCK, ICON_LOCK_STRONG, ICON_WARN, ICON_WH_BOOK_CLOSED, ICON_WH_BOOK_OPEN, INFORMATION_MSG, JALIOS_JUNIT_PROP, JCMS_CADDY, JSYNC_DOWNLOAD_DIR, JSYNC_SYNC_ALARM, LOG_FILE, LOG_TOPIC_SECURITY, LOGGER_PROP, LOGGER_XMLPROP, MBR_PHOTO_DIR, MDATE_SEARCH, MONITOR_XML, OP_CREATE, OP_DEEP_COPY, OP_DEEP_DELETE, OP_DELETE, OP_MERGE, OP_UPDATE, PDATE_SEARCH, PHOTO_LARGE, PHOTO_LARGE_HEIGHT, PHOTO_LARGE_WIDTH, PHOTO_NORMAL, PHOTO_NORMAL_HEIGHT, PHOTO_NORMAL_WIDTH, PHOTO_SMALL, PHOTO_SMALL_HEIGHT, PHOTO_SMALL_WIDTH, PHOTO_TINY, PHOTO_TINY_HEIGHT, PHOTO_TINY_WIDTH, PREVIOUS_TAB, PRINT_VIEW, PRIVATE_FILE_ACCESS, PUBLIC_FILE_ACCESS, READ_RIGHT_TAB, SDATE_SEARCH, SEARCHENGINE_ALARM, SESSION_AUTHORIZED_FILENAMES_SET, STATS_REPORT_DIR, STATUS_PROP, STORE_XML, TEMPLATE_TAB, THUMBNAIL_LARGE_HEIGHT, THUMBNAIL_LARGE_WIDTH, THUMBNAIL_SMALL_HEIGHT, THUMBNAIL_SMALL_WIDTH, UDATE_SEARCH, UPDATE_RIGHT_TAB, UPLOAD_DIR, URL_REGEXP, WARNING_MSG, WEBAPP_PROP, WFEXPRESS_ALARM, WFREMINDER_ALARM, WORKFLOW_TAB, WORKFLOW_XML
 
Fields inherited from interface com.jalios.util.JaliosConstants
CRLF, MILLIS_IN_ONE_DAY, MILLIS_IN_ONE_HOUR, MILLIS_IN_ONE_MINUTE, MILLIS_IN_ONE_MONTH, MILLIS_IN_ONE_SECOND, MILLIS_IN_ONE_WEEK, MILLIS_IN_ONE_YEAR
 
Constructor Summary
PortalElement()
           
PortalElement(PortalElement other)
           
 
Method Summary
 boolean containsTreeDescendant(TreeNode tn)
           
 PortalElement duplicate(Member author)
          Duplicate a PortalElement using one of its default constructor, and create it in the store.
 PortalElement duplicate(String prefix, Member author)
          Duplicates a PortalElement and add a Prefix to the title.
 PortalElement duplicate(String prefix, Member author, boolean deep)
          Performs a deep duplicate.
 PortalElement duplicate(String prefix, Member author, boolean deep, Workspace wkspc, Map catMap, Map groupMap)
          Deprecated. Used instead duplicate(WizardContext, boolean)
 PortalElement duplicate(WizardContext context, boolean deep)
          Performs a deep duplicate.
protected  void duplicateDeep(PortalElement parent, String prefix, Member author, Workspace wkspc, Map catMap, Map groupMap)
          Deprecated. Used instead duplicateDeep(WizardContext, PortalElement)
protected  void duplicateDeep(WizardContext context, PortalElement parent)
          Performs a deep duplicate of the PortalElement in a WizardContext.
 String[] getAbilities()
           
 String[] getAbilities(String lang)
           
 String[] getAbilities(String lang, boolean useDefault)
           
 String getAbilityLabel(String userLang, String ability)
          Returns the label of a given ability
static PortalElement.AbilitySelector getAbilitySelector(String ability)
          Retrieves a new instance of PortalElement.AbilitySelector using the specified ability String.
 String getAbstract()
          Returns the abstract of this publication in the channel's main language.
 String getAbstract(String lang, boolean useDefault)
          Returns the abstract of this publication.
static String[] getAllAbilities()
          Returns an Array of all available abilities declared for the given class.
static String[] getAllAbilities(Class clazz)
          Returns an Array of all available abilities declared for the given class
static Map getAllAbilityMap()
          Returns a Map (key1/key2) of all available abilities declared.
 Collection<PortalElement> getAllTreeChildren()
          Retrieve a new collection containing all PortalElement children of this PortalElement
abstract  String getBehaviorCopy()
           
abstract  String getCacheSensibility()
           
abstract  String getCacheType()
           
 int getCacheTypeInt()
           
 String getContentTitle(String lang)
           
abstract  String getCssClasses()
           
abstract  String getCssId()
           
 String getDefaultTemplateUsage()
          Returns the default template usage used to display the publication.
abstract  String getDescription(String lang)
           
abstract  String getDescription(String lang, boolean b)
           
abstract  HashMap<String,String> getDescriptionML()
           
 String getIcon()
           
abstract  String[] getInvalidClass()
           
abstract  long getInvalidTime()
           
abstract  String getPortletImage(String lang)
           
abstract  String getPortletImage(String lang, boolean b)
           
abstract  HashMap<String,String> getPortletImageML()
           
 String getPreview(JcmsJspContext ctxt, int width, int height, String defaultImagePath)
          Retrieve the preview image of this Portlet in the specified context and dimensions.
 Class[] getResolvedInvalidClass()
           
 String getSkinPath(JcmsJspContext ctxt)
          Returns the template skin path for the given usage
 String getSkinPath(String usage, boolean devModeChecks)
          Returns the template skin path for the given usage
 TypeTemplateEntry getSkinTemplateEntry(String usage, boolean devModeChecks)
          Returns the TypeTemplateEntry Skin matching the given parameters.
 Collection<? extends TreeNode> getTreeChildren()
          Returns a Collection of TreeNode children of the current node
 TreeNode getTreeParent()
          Returns parent of the current node
 TreeNode getTreeParent(TreeNode node)
           
 boolean hasAbility()
          Returns true if the portlet has an ability
 boolean hasAbility(String ability)
          Returns true if the portlet have the given ability Or if the ability is empty and the portlet have no ability
 boolean hasCacheGroups()
           
 boolean hasCacheMembers()
           
 boolean hasCacheServer()
           
 boolean hasCacheSession()
           
 boolean hasCacheSessionAndVisitors()
           
 boolean hasCacheVisitorsOnly()
           
 boolean hasCurrentCategoryCacheSensibility()
           
 boolean hasNoCache()
           
 boolean hasNoCacheSensibility()
           
 boolean hasPortalCategoryCacheSensibility()
           
 boolean isChildTreeNode(TreeNode child)
           
 boolean isCopy()
           
 boolean isReference()
           
 boolean isTreeLeaf()
          Returns boolean true if the TreeNode is a leaf
 boolean isTreeNode()
          Returns boolean true if the TreeNode is a node
 boolean isWorkspaceReference()
           
 void performUpdate(Member mbr, Map context)
          Performs data update
 void setAbilities(String[] v)
           
abstract  void setBehaviorCopy(String b)
           
abstract  void setCacheSensibility(String v)
           
abstract  void setCacheType(String v)
           
abstract  void setCssClasses(String v)
           
abstract  void setCssId(String v)
           
abstract  void setDescription(String s)
           
abstract  void setDescriptionML(HashMap<String,String> s)
           
abstract  void setInvalidClass(String[] v)
           
abstract  void setInvalidTime(long v)
           
abstract  void setPortletImage(String s)
           
abstract  void setPortletImageML(HashMap<String,String> s)
           
 
Methods inherited from class com.jalios.jcms.Publication
addAuthorizedGroup, addAuthorizedMember, addCategory, addWeakReferrer, addWFExpressAlarm, addWFReminderAlarm, assignCommonPublicationFields, assignRole, assignRole, canBeArchived, canBeArchived, canBeEditedFieldByField, canBeReadBy, canBeReadBy, canBeReadBy, canCreateCopy, canCreateCopy, canCreateWorkCopy, canMergeWorkCopy, checkCreate, checkDelete, checkIntegrity, checkLang, checkMember, checkMerge, checkStateChange, checkTemplateEntry, checkUpdate, checkWrite, clearTransientIndex, computeSignature, containsCategory, createCopy, createWFNote, createWorkCopy, exportXmlField, getAbstract, getAbstractML, getAccessCount, getAdate, getAdateComparator, getAdateSelector, getAllFilePath, getAllWikiText, getAllWysiwygText, getAudiencedRightsString, getAudienceRightComparator, getAudienceRightSelector, getAuthorizedGroupSet, getAuthorizedMemberSet, getAuthorizedSelector, getCanWorkOnSelector, getCategories, getCategories, getCategorySet, getComparator, getComparator, getComparator, getCSVHeader, getDataName, getDate, getDate, getDateSelector, getDdateComparator, getDescendantCategorySet, getDescendantCategorySet, getDescendantCategorySet, getDisplayTemplateFile, getDocumentLinkSet, getEdate, getEdateComparator, getEdateSelector, getEstimatedReminderCount, getExternalLinkSet, getFieldInMainLanguage, getFieldValue, getFirstDescendantCategory, getFirstDescendantCategory, getFirstDescendantCategory, getFriendlyURLSet, getGlobalRating, getImportConflictCopy, getImportVersion, getIndexingDate, getLinkDataSet, getMainInstance, getMainLanguage, getMajorVersion, getMemberSetAssignedToRole, getMergeDate, getMergeId, getMinorVersion, getNextWFStateSet, getPdate, getPdateComparator, getPdateSelector, getPstatus, getPstatusAlarmEntry, getPstatusComparator, getPstatusSelector, getPstatusSelector, getQueryTemplateFile, getRatingComparator, getReaderComparator, getReaderCount, getReaderTrackerList, getReadRightSelector, getReadRightsString, getReview, getReviewCount, getReviewCountComparator, getReviewList, getReviewList, getRightComparator, getRoleMap, getSdate, getSdateComparator, getSdateSelector, getSearchStrings, getTemplate, getTemplateEntry, getTemplateEntry, getTemplateEntrySet, getTemplatePath, getTemplatePath, getTemplates, getTitle, getTitle, getTitle, getTitleComparator, getTitleComparator, getTitleML, getTrackedSelector, getTreeRoot, getTypeComparator, getTypeLabel, getUdate, getUdateComparator, getUdateSelector, getUpdateGroupSet, getUpdateMemberSet, getVersionString, getVisibleStateSelector, getWeakReferrerSet, getWFNoteList, getWFState, getWFStateLabel, getWorkCopySet, getWorkflow, getWorkspace, getWorkspaceAuthorSelector, getWorkspaceComparator, getWorkspaceId, getWorkspaceSelector, getWSTypeEntry, getWSTypeEntry, hasAlreadyVoted, hasAnyReadRights, hasBeenReadBy, hasCategory, hasImportConflict, hasNoReadRights, hasReview, hasWeakReferrers, importConvertToLocal, importMarkAsMerged, importOverrideAndUpdate, importXml, init, initCopy, isAudienced, isDefaultTemplate, isImportConflictCopy, isInRole, isInVisibleState, isPublic, isRoleAssigned, isTracked, isUserContent, isUserContentType, isWorkCopy, majorUpdate, performCreate, performDelete, performMerge, performMerge, prepareMergeCopy, putPstatusAlarmEntry, removeAllDescendants, removeAllReaderTracker, removeAuthorizedGroup, removeAuthorizedMember, removeCategory, removeDataSet, removeImportMetadata, removePstatusAlarmEntry, removeWeakReferrer, removeWFExpressAlarm, removeWFReminderAlarm, resolveTypeTemplateEntry, setAdate, setAuthorizedGroupSet, setAuthorizedMemberSet, setCategories, setCategorySet, setCdate, setEdate, setFriendlyURLSet, setImportConflictCopy, setImportVersion, setMainInstance, setMainLanguage, setMajorVersion, setMergeDate, setMergeId, setPdate, setPstatus, setRoleMap, setRoleMemberSetMap, setSdate, setTemplate, setTemplates, setTitle, setTitle, setTitleML, setTracked, setUdate, setUpdateGroupSet, setUpdateMemberSet, setWorkspace, setWorkspaceId, toCSV, toFullString, toString, trackReader, unassignMember, unassignRole, updatePstatus, updateTemplate
 
Methods inherited from class com.jalios.jcms.Data
checkCreate, checkDelete, checkIntegrity, checkLock, checkUpdate, clone, computeDBIDArray, exportXml, exportXml, exportXml, exportXml, exportXmlRelated, exportXmlRelated, fillExportXmlFieldAttributes, getAllReferrerSet, getAllReferrerSet, getAllTypeFieldEntry, getAuthor, getAuthor, getAuthorComparator, getAuthorDBID, getAuthorId, getAuthorSelector, getBooleanFieldValue, getCaddyComparator, getCategoryFieldValue, getCdateSelector, getDataImage, getDataImage, getDataImage, getDataNameComparator, getDeletableSelector, getDisplayUrl, getDoubleFieldValue, getExportXmlDataValue, getExtension, getExtraData, getExtraDataMap, getExtraDBData, getExtraDBDataMap, getExtraInfo, getExtraInfoMap, getFieldStatusMap, getFieldValue, getFieldValue, getFieldValue, getImportAuthor, getImportBatch, getImportDate, getImportDisplayUrl, getImportId, getImportMap, getImportMdate, getImportSelector, getImportSignature, getImportSource, getImportSourceUrl, getImportUrl, getIntFieldValue, getIntFieldValue, getLinkCount, getLinkIndexedDataSet, getLinkIndexedDataSet, getLockDate, getLockMember, getLongFieldValue, getMdateSelector, getNewDefaultExtraDataMap, getNewDefaultExtraDataMap, getNewDefaultExtraDataMap, getNewDefaultExtraDataMap, getNewDefaultExtraDBDataMap, getNewDefaultExtraDBDataMap, getNewDefaultExtraDBDataMap, getNewDefaultExtraDBDataMap, getOpAuthor, getOpAuthorComparator, getOpDelegate, getRowId, getTypeEntry, getTypeFieldsEntries, getUpdateInstance, hashCode, importXmlFieldsWithReferences, importXmlFiles, importXmlReferences, isImported, isImportUpdated, isInDatabase, isLocked, isPersisted, lock, markNewImport, mergeHybridLink, performAfterWrite, performBeforeWrite, performCreate, performDelete, performUpdate, removeExtraData, removeExtraDBData, removeExtraInfo, setAuthor, setAuthorDBID, setAuthorId, setExtension, setExtraData, setExtraDataMap, setExtraDBData, setExtraDBDataMap, setExtraInfo, setImportAuthor, setImportBatch, setImportDate, setImportDisplayUrl, setImportId, setImportMap, setImportMdate, setImportSignature, setImportSource, setImportSourceUrl, setImportUpdated, setMdate, setOpAuthor, setOpDelegate, setRowId, unlock, unlock, unmarkNewImport, updateExtraDataMap, updateExtraDBDataMap, updateIndexTreeSet
 
Methods inherited from class com.jalios.jstore.BasicStorable
clearId, compareTo, equals, getAttribute, getAttributes, getCdate, getCdateComparator, getDdate, getId, getIdComparator, getMdate, getMdateComparator, getStore, getUrid, hasBeenUpdated, isStored, resolveAtt, resolveVal, setAttributes, setDdate, setId, setStore, toXml
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface com.jalios.util.TreeNode
getTreeRoot
 

Field Detail

REVISION

public static final String REVISION
See Also:
Constant Field Values

tteDefault

protected static TypeTemplateEntry tteDefault

abilities

protected String[] abilities

allAbilities

protected static transient String[] allAbilities

allAbilityMap

protected static transient Map allAbilityMap

cachedAbilities

protected transient List cachedAbilities

ICON_PORTLET

public static final String ICON_PORTLET
See Also:
Constant Field Values

ICON_STATS

public static final String ICON_STATS
See Also:
Constant Field Values
Constructor Detail

PortalElement

public PortalElement()

PortalElement

public PortalElement(PortalElement other)
Method Detail

getContentTitle

public String getContentTitle(String lang)

getAbstract

public String getAbstract()
Description copied from class: Publication
Returns the abstract of this publication in the channel's main language.

Overrides:
getAbstract in class Publication
Returns:
the abstract of this publication in the channel's main language.

getAbstract

public String getAbstract(String lang,
                          boolean useDefault)
Description copied from class: Publication
Returns the abstract of this publication.

Overrides:
getAbstract in class Publication
Parameters:
lang - the user language (ISO-639 language code)
useDefault - should the default language be used
Returns:
the abstract of this publication.

getDescriptionML

public abstract HashMap<String,String> getDescriptionML()

getDescription

public abstract String getDescription(String lang)

getDescription

public abstract String getDescription(String lang,
                                      boolean b)

setDescription

public abstract void setDescription(String s)

setDescriptionML

public abstract void setDescriptionML(HashMap<String,String> s)

getPortletImageML

public abstract HashMap<String,String> getPortletImageML()

getPortletImage

public abstract String getPortletImage(String lang)

getPortletImage

public abstract String getPortletImage(String lang,
                                       boolean b)

setPortletImage

public abstract void setPortletImage(String s)

setPortletImageML

public abstract void setPortletImageML(HashMap<String,String> s)

getPreview

public String getPreview(JcmsJspContext ctxt,
                         int width,
                         int height,
                         String defaultImagePath)
Retrieve the preview image of this Portlet in the specified context and dimensions.

Current implementation is as follow :
If the portlet image of this portlet has been defined, it is used as the source image for the preview. Otherwise the preview of the template being use for the specified context is used.

Then, the thumbnail tag is used to create the image in the appropriate dimension, from this source, if the source image file could no be found, the default image specified in parameters is used.

Warning : This method create a thumbnail when it does not exists, this process can be a little time consumming, make sure you do not need immediate response time when using it, as it might slow down your jsp access time (on first call only).

Parameters:
ctxt - the current JcmsJspContext
width - target max width (if a value of 0 or less is specified, 200 will be used)
height - target max height (if a value of 0 or less is specified, 150 will be used)
defaultImagePath - the default image to use if thumbnail do not exists
Returns:
a path relative to the webapp root (e.g. "types/PortletRSS/th-60x45-doPortletRSSFullDisplay.jpg.jpg").

getCssId

public abstract String getCssId()

setCssId

public abstract void setCssId(String v)

getCssClasses

public abstract String getCssClasses()

setCssClasses

public abstract void setCssClasses(String v)

getDefaultTemplateUsage

public String getDefaultTemplateUsage()
Returns the default template usage used to display the publication. This default tempalte may change between Content and Portlets

Overrides:
getDefaultTemplateUsage in class Publication
Returns:
String the default usage
See Also:
Publication.getDefaultTemplateUsage()

getSkinPath

public String getSkinPath(String usage,
                          boolean devModeChecks)
Returns the template skin path for the given usage

Parameters:
usage - the template usage
devModeChecks - perform developement checks on template
Returns:
String the path of the template used

getSkinPath

public String getSkinPath(JcmsJspContext ctxt)
Returns the template skin path for the given usage

Parameters:
ctxt - the JcmsJspContext
Returns:
String the path of the template used

getSkinTemplateEntry

public TypeTemplateEntry getSkinTemplateEntry(String usage,
                                              boolean devModeChecks)
Returns the TypeTemplateEntry Skin matching the given parameters. It returns a default template if the given one does work.

Parameters:
usage - the template usage
devModeChecks - perform developement checks on template
Returns:
TypeTemplateEntry the matching templates
See Also:
Publication.checkTemplateEntry(TypeTemplateEntry, String, boolean, String)

getCacheType

public abstract String getCacheType()

setCacheType

public abstract void setCacheType(String v)

getCacheSensibility

public abstract String getCacheSensibility()

setCacheSensibility

public abstract void setCacheSensibility(String v)

getInvalidClass

public abstract String[] getInvalidClass()

setInvalidClass

public abstract void setInvalidClass(String[] v)

getInvalidTime

public abstract long getInvalidTime()

setInvalidTime

public abstract void setInvalidTime(long v)

getResolvedInvalidClass

public Class[] getResolvedInvalidClass()

hasNoCacheSensibility

public boolean hasNoCacheSensibility()

hasPortalCategoryCacheSensibility

public boolean hasPortalCategoryCacheSensibility()

hasCurrentCategoryCacheSensibility

public boolean hasCurrentCategoryCacheSensibility()

getCacheTypeInt

public int getCacheTypeInt()

hasNoCache

public boolean hasNoCache()

hasCacheSession

public boolean hasCacheSession()

hasCacheServer

public boolean hasCacheServer()

hasCacheGroups

public boolean hasCacheGroups()

hasCacheMembers

public boolean hasCacheMembers()

hasCacheSessionAndVisitors

public boolean hasCacheSessionAndVisitors()

hasCacheVisitorsOnly

public boolean hasCacheVisitorsOnly()

getBehaviorCopy

public abstract String getBehaviorCopy()

setBehaviorCopy

public abstract void setBehaviorCopy(String b)

isCopy

public boolean isCopy()

isReference

public boolean isReference()

isWorkspaceReference

public boolean isWorkspaceReference()

duplicate

public PortalElement duplicate(Member author)
Duplicate a PortalElement using one of its default constructor, and create it in the store. If an exception append then return null.

Parameters:
author - the Member to be used for store operation (create).
Returns:
a newly created PortalElement instance, duplicate of this
Since:
jcms-4.0

duplicate

public PortalElement duplicate(String prefix,
                               Member author)
Duplicates a PortalElement and add a Prefix to the title.

Parameters:
prefix - the title prefix
author - the Member to be used for store operation (create).
Returns:
a newly created PortalElement instance, duplicate of this
Since:
jcms-4.0

duplicate

public PortalElement duplicate(String prefix,
                               Member author,
                               boolean deep)
Performs a deep duplicate.

Parameters:
prefix - the title prefix
author - the Member to be used for store operation (create).
deep - boolean indicating if it is a deep copy
Returns:
a newly created PortalElement instance, duplicate of this
Since:
jcms-4.0

duplicate

public PortalElement duplicate(String prefix,
                               Member author,
                               boolean deep,
                               Workspace wkspc,
                               Map catMap,
                               Map groupMap)
Deprecated. Used instead duplicate(WizardContext, boolean)

Performs a deep duplicate.

Parameters:
prefix - the title prefix
author - the author who perform the action
deep - boolean indicate if it is a deep copy
wkspc - the workspace to set
catMap - the binding map of old/new categories
groupMap - the binding map of old/new groups
Returns:
a newly created PortalElement instance, duplicate of this
Since:
jcms-4.1

duplicate

public PortalElement duplicate(WizardContext context,
                               boolean deep)
Performs a deep duplicate.

Parameters:
context - WizardContext describe the dupliate context
deep - boolean indicating if it is a deep copy
Returns:
a newly created PortalElement instance, duplicate of this
Since:
jcms-5.7.3

duplicateDeep

protected void duplicateDeep(PortalElement parent,
                             String prefix,
                             Member author,
                             Workspace wkspc,
                             Map catMap,
                             Map groupMap)
Deprecated. Used instead duplicateDeep(WizardContext, PortalElement)

Performs a deep duplicate of the PortalElement in a WizardContext. Update prefix, workspace, category, groups, ...

Parameters:
parent - the duplicated parent (Not already created in JCMS)
prefix - the title prefix
author - the author who perform the action
wkspc - the workspace to set
catMap - the binding map of old/new categories
groupMap - the binding map of old/new groups
Since:
jcms-4.1

duplicateDeep

protected void duplicateDeep(WizardContext context,
                             PortalElement parent)
Performs a deep duplicate of the PortalElement in a WizardContext. Update prefix, workspace, category, groups, ...

Parameters:
context - WizardContext describe the dupliate context
parent - PortalElement parent of portlets to deeply duplicate
Since:
jcms-5.7.3

getAbilities

public String[] getAbilities()

getAbilities

public String[] getAbilities(String lang)

getAbilities

public String[] getAbilities(String lang,
                             boolean useDefault)

setAbilities

public void setAbilities(String[] v)

hasAbility

public boolean hasAbility(String ability)
Returns true if the portlet have the given ability Or if the ability is empty and the portlet have no ability

Parameters:
ability - Strign representing the ability
Returns:
boolean true if the portlet has the ability

hasAbility

public boolean hasAbility()
Returns true if the portlet has an ability

Returns:
boolean true if the portlet has an ability

getAllAbilityMap

public static Map getAllAbilityMap()
Returns a Map (key1/key2) of all available abilities declared. This methode use a cached Map of abilities.

Returns:
Map of abilities

getAllAbilities

public static String[] getAllAbilities()
Returns an Array of all available abilities declared for the given class. This methode use cached abilities.

Returns:
String[] an array of abilities

getAllAbilities

public static String[] getAllAbilities(Class clazz)
Returns an Array of all available abilities declared for the given class

Parameters:
clazz - the class used to filter abilities
Returns:
String[] an array of abilities

getAbilityLabel

public String getAbilityLabel(String userLang,
                              String ability)
Returns the label of a given ability

Parameters:
userLang - the user language
ability - the ability
Returns:
String the I18N ability

getIcon

public String getIcon()

getTreeChildren

public Collection<? extends TreeNode> getTreeChildren()
Description copied from interface: TreeNode
Returns a Collection of TreeNode children of the current node

Specified by:
getTreeChildren in interface TreeNode
Overrides:
getTreeChildren in class Publication
Returns:
Collection of TreeNode
See Also:
TreeNode.getTreeChildren()

isTreeLeaf

public boolean isTreeLeaf()
Description copied from interface: TreeNode
Returns boolean true if the TreeNode is a leaf

Specified by:
isTreeLeaf in interface TreeNode
Overrides:
isTreeLeaf in class Publication
Returns:
boolean indicating if node is leaf or node
See Also:
TreeNode.isTreeLeaf()

isTreeNode

public boolean isTreeNode()
Description copied from interface: TreeNode
Returns boolean true if the TreeNode is a node

Specified by:
isTreeNode in interface TreeNode
Overrides:
isTreeNode in class Publication
Returns:
boolean indicating if node is leaf or node
See Also:
TreeNode.isTreeNode()

getTreeParent

public TreeNode getTreeParent()
Description copied from interface: TreeNode
Returns parent of the current node

Specified by:
getTreeParent in interface TreeNode
Overrides:
getTreeParent in class Publication
Returns:
TreeNode parent Node
See Also:
TreeNode.getTreeParent()

getTreeParent

public TreeNode getTreeParent(TreeNode node)

isChildTreeNode

public boolean isChildTreeNode(TreeNode child)

getAllTreeChildren

public Collection<PortalElement> getAllTreeChildren()
Retrieve a new collection containing all PortalElement children of this PortalElement

Returns:
a new Collection of PortalElement.

containsTreeDescendant

public boolean containsTreeDescendant(TreeNode tn)

performUpdate

public void performUpdate(Member mbr,
                          Map context)
Description copied from class: Publication
Performs data update

Overrides:
performUpdate in class Publication
Parameters:
mbr - the member which requests the write operation
context - a map which contains context parameters (may be null)

getAbilitySelector

public static PortalElement.AbilitySelector getAbilitySelector(String ability)
Retrieves a new instance of PortalElement.AbilitySelector using the specified ability String.

Parameters:
ability - an ability choosen from values returned by getAllAbilities(), or "noabilities" for portlet without any ability, or "hasabilities" for portlet with any ability.
Returns:
a new instance of PortalElement.AbilitySelector using the given ability String.
Since:
jcms-5.7.1


Copyright © 2001-2007 Jalios SA. All Rights Reserved.