public abstract class Publication extends Data implements ImportConstants, EditableData, Searchable, TreeNode
Modifier and Type | Class and Description |
---|---|
static class |
Publication.AdateComparator<T extends Publication>
Compares two Publications using their Adate in descending order (newest date first).
|
static class |
Publication.AdateSelector
AdateSelector selects all the publications with a adate in a given range
|
static class |
Publication.AudienceRightComparator<T extends Publication>
Comparator to compare Publication using their audience rights.
|
static class |
Publication.AudienceRightSelector
AudienceRightSelector selects all publications being audienced.
|
static class |
Publication.AuthorComparator<T extends Publication> |
static class |
Publication.AuthorizedSelector
AuthorizedSelector selects all the publications a member is
authorized to read.
|
static class |
Publication.CanWorkOnSelector
CanWorkOnSelector selects all the publications a member can
work on.
|
static class |
Publication.DdateComparator<T extends Publication>
Compares two Publications using their Ddate in descending order (newest date first).
|
static class |
Publication.EdateComparator<T extends Publication>
Compares two Publications using their Edate in descending order (newest date first).
|
static class |
Publication.EdateSelector
EdateSelector selects all the publications with a edate in a given range
|
static class |
Publication.PdateComparator<T extends Publication>
Compares two Publications using their Pdate in descending order (newest date first).
|
static class |
Publication.PdateSelector
PdateSelector selects all the publications with a pdate in a given range
|
static class |
Publication.PopularityComparator<T extends Publication>
Comparator to compare Publication using their score based on votes
|
static class |
Publication.PstatusComparator<T extends Publication> |
static class |
Publication.PstatusSelector
PstatusSelector selects all the publications with a given pstatus.
|
static class |
Publication.ReaderComparator<T extends Publication> |
static class |
Publication.ReadRightSelector
ReadRightSelector selects all publications which have any read right.
|
static class |
Publication.RightComparator<T extends Publication> |
static class |
Publication.SdateComparator<T extends Publication>
Compares two Publications using their Sdate in descending order (newest date first).
|
static class |
Publication.SdateSelector
SdateSelector select all the publications with a sdate in a given range
|
static class |
Publication.TitleComparator<T extends Publication> |
static class |
Publication.TrackedSelector
TrackedSelector selects all the publications which are tracked.
|
static class |
Publication.TypeComparator<T extends Publication> |
static class |
Publication.UdateComparator<T extends Publication>
Compares two Publications using their udate in descending order (newest date first).
|
static class |
Publication.UdateSelector
UdateSelector selects all the publications with a udate in a given range
|
static class |
Publication.UserContentSelector
UserContentSelector selects all publications which are UGC (UserContent).
|
static class |
Publication.VisibleStateSelector
VisibleStateSelector selects all the publications which are in a visible state
|
static class |
Publication.VoteScoreComparator<T extends Publication>
Comparator to compare Publication using their score based the score of votes (positive votes - negative votes)
|
static class |
Publication.WorkspaceAuthorSelector
WorkspaceAuthorSelector selects all the publication the given
member is the author and which belong to the given workspace.
|
static class |
Publication.WorkspaceComparator<T extends Publication> |
static class |
Publication.WorkspaceSelector
WorkspaceSelector selects all the publications which belong to
the given workspace.
|
Data.AuthorSelector, Data.CdateSelector, Data.DataNameComparator<T extends Data>, Data.DeletableSelector, Data.ImportSelector, Data.MdateSelector, Data.OpAuthorComparator<T extends Data>, Data.RowIdComparator<T extends Data>, Data.StrongLockSelector
BasicStorable.CdateComparator<T extends Storable>, BasicStorable.IdComparator<T extends Storable>, BasicStorable.MdateComparator<T extends Storable>
Modifier and Type | Field and Description |
---|---|
protected java.util.Date |
adate |
protected java.util.Set<java.lang.String> |
allCatIdSet |
protected java.util.Set<java.lang.String> |
authGrpIdSet |
protected boolean |
authGrpIdSetDirty |
protected boolean |
authGrpIdSetInit |
protected java.util.Set<java.lang.String> |
authMbrIdSet |
protected boolean |
authMbrIdSetDirty |
protected boolean |
authMbrIdSetInit |
protected java.util.TreeSet<Group> |
authorizedGroupSet |
protected java.util.TreeSet<Member> |
authorizedMemberSet |
protected Category[] |
categories |
protected java.util.TreeSet<Category> |
categorySet |
protected java.util.Set<java.lang.String> |
catIdSet |
protected boolean |
catIdSetDirty |
protected boolean |
catIdSetInit |
static int |
CTRL_TOPIC_ADVANCED |
static int |
CTRL_TOPIC_CATEGORIES |
static int |
CTRL_TOPIC_WORKFLOW |
protected java.util.Date |
edate |
protected java.util.TreeSet<java.lang.String> |
friendlyURLSet |
protected boolean |
hasNoReadRightsDBData |
protected static PublicationIndexManager |
indexMgr |
protected boolean |
isTracked |
protected Publication |
mainInstance |
protected java.lang.String |
mainLanguage |
protected int |
majorVersion |
protected java.util.Date |
mergeDate |
protected java.lang.String |
mergeId |
protected int |
minorVersion |
protected java.util.Date |
pdate |
protected int |
pstatus |
static java.lang.String |
PUBLICATION_WFNOTE |
protected int |
readerCount |
static java.lang.String |
REVISION |
protected java.util.HashMap<java.lang.String,java.util.TreeSet<Member>> |
roleMap |
protected java.util.Date |
sdate |
protected java.lang.String[] |
templates |
protected java.lang.String |
title |
protected java.util.HashMap<java.lang.String,java.lang.String> |
titleML |
protected java.util.Date |
udate |
protected java.util.TreeSet<Group> |
updateGroupSet |
protected java.util.TreeSet<Member> |
updateMemberSet |
protected int |
voteCount |
protected int |
voteScore |
protected AlarmEntry |
wfExpressAlarmEntry |
protected AlarmEntry |
wfReminderAlarmEntry |
protected java.lang.String |
workflowId |
protected Workspace |
workspace |
author, authorDBID, channel, DISPLAY_URL_EXTRA_INFO, extension, extraDataMap, extraDBDataMapToSaveOnOp, importMap, opAuthor, opDelegate
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
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
ADATE_SEARCH, ADMIN_NOTES_PROP, ADVANCED_TAB, ARCHIVES_DIR, ASCII_WIDTH, CATEGORY_TAB, CDATE_SEARCH, COMMON_ALARM, CONTENT_TAB, COOKIE_MAX_AGE, 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, JCMS_MSG_LIST, 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_CREATE_STR, OP_DEEP_COPY, OP_DEEP_COPY_STR, OP_DEEP_DELETE, OP_DEEP_DELETE_STR, OP_DELETE, OP_DELETE_STR, OP_MERGE, OP_MERGE_STR, OP_UPDATE, OP_UPDATE_STR, PDATE_SEARCH, PHOTO_DIR, PHOTO_ICON, PHOTO_ICON_HEIGHT, PHOTO_ICON_WIDTH, 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, TYPES_ICON_ALT_PROP, TYPES_ICON_SUFFIX_PROP, TYPES_ICON_TITLE_PROP, TYPES_PREFIX_PROP, TYPES_THUMB_SUFFIX_PROP, UDATE_SEARCH, UPDATE_RIGHT_TAB, UPLOAD_DIR, URL_REGEXP, WARNING_MSG, WEBAPP_PROP, WFEXPRESS_ALARM, WFREMINDER_ALARM, WORKFLOW_TAB, WORKFLOW_XML
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 and Description |
---|
Publication() |
Publication(Publication other) |
Modifier and Type | Method and Description |
---|---|
void |
addAuthorizedGroup(Group grp)
Add an authorized group
|
void |
addAuthorizedMember(Member mbr)
Add an authorized member.
|
void |
addCategory(Category cat)
Add the given category to the categories of this publication
|
void |
addFollower(Member mbr)
Adds a follower for this publication.
|
void |
addWeakReferrer(Publication referrer)
Add a weak referrer.
|
void |
addWFExpressAlarm()
Adds a WFExpress alarm for this publication (only for main leader replica).
|
void |
addWFReminderAlarm()
Adds a WFReminder alarm for this publication (only for main leader replica).
|
void |
assignCommonPublicationFields(Publication pub)
Assign all the common fields (author, workspace, pstatus, pdate, ...)
|
void |
assignRole(java.lang.String roleId,
Member mbr)
Assigns a member to a role
|
void |
assignRole(java.lang.String roleId,
java.util.TreeSet<Member> mbrSet) |
boolean |
canBeArchived(Member mbr)
Check if the publication can be archived by the given member.
|
ControllerStatus |
canBeArchived(Member mbr,
java.util.Map context)
Returns a ControllerStatus indicating if this publication can be archived or not
|
boolean |
canBeEditedFieldByField(Member mbr)
Returns true if this publication can be edited field by field on the front-office by the given member.
|
boolean |
canBeFollowedBy(Member mbr)
Returns true if the given member can follow this publication
|
boolean |
canBeReadBy(Group group)
Checks if a group can read this publication.
|
boolean |
canBeReadBy(Group group,
RightInfo rightInfo) |
boolean |
canBeReadBy(Member member)
This convenient method is the same that canBeReadBy(member, true).
|
boolean |
canBeReadBy(Member member,
boolean searchInGroups)
Check if a member can read this publication.
|
boolean |
canBeReadBy(Member member,
boolean searchInGroups,
RightInfo rightInfo) |
boolean |
canBeVotedBy(Member mbr) |
boolean |
canCreateCopy(Member mbr)
Returns true if the given member can create a copy of this publication
|
boolean |
canCreateCopy(Member mbr,
boolean isWorkCopy)
Returns true if the given member can create a copy of this publication
|
boolean |
canCreateWorkCopy(Member mbr)
Returns true if the given member can create a work copy of this publication
|
boolean |
canMergeWorkCopy(Member mbr)
Returns true if the given member can merge this work copy with it's main instance
|
boolean |
canRequestUnlock(Member mbr)
Returns true if the given member can request to unlock this document.
|
ControllerStatus |
checkCreate(Member mbr,
java.util.Map context)
Checks if the creation can be performed
|
ControllerStatus |
checkDelete(Member mbr,
java.util.Map context)
Checks if the deletion can be performed
|
ControllerStatus |
checkIntegrity()
Checks whether or not data integrity constraints are respected.
|
boolean |
checkLang(java.lang.String lang)
Check if the publication is available for the given
language.
|
ControllerStatus |
checkMember(int op,
Member mbr,
java.util.Map context)
Checks if the given member can perform the given operation.
|
ControllerStatus |
checkMerge(Member mbr,
java.util.Map context)
Checks if the merge can be performed
|
java.lang.Object[] |
checkStateChange(Member mbr,
int newPstatus)
Checks if the state change can be performed (it checks if the transition's rule can be perfomed)
|
java.lang.Object[] |
checkStateChange(Member mbr,
int newPstatus,
int oldPstatus)
Checks if the state change can be performed (it checks if the transition's rule can be perfomed)
|
protected static boolean |
checkTemplateEntry(TypeTemplateEntry tte,
java.lang.String usage,
boolean devModeChecks,
java.lang.String label)
Checks if the given TypeTemplateEntry is matching dev modes
In developpement mode it throws exception if template is null or jsp is missing
In production mode it returns default template if template is null but do not check
if JSP template exists to improve performances.
|
ControllerStatus |
checkUpdate(Member mbr,
java.util.Map context)
Checks if the update can be performed
|
ControllerStatus |
checkWrite(int op,
Member mbr,
boolean checkIntegrity,
java.util.Map context)
Checks if the given write operation can be performed
|
void |
clearTransientIndex()
Clear all the transient fields that contains indexes.
|
void |
cloneDBDataCollections() |
java.lang.String |
computeSignature()
Deprecated.
use #computeSignature(boolean, boolean)
|
java.lang.String |
computeSignature(boolean includePublicationFields,
boolean hash)
Compute the signature of this publication.
|
boolean |
containsCategory(Category category)
This convenient method returns true if the publication contains a
given category.
|
Publication |
createCopy(Member mbr)
Creates a copy from this publication
|
boolean |
createWFNote(Member mbr,
int newPstatus,
int oldPstatus,
java.lang.String note)
Create/Update a WFNote and check if the transition can be performed.
|
boolean |
createWFNote(Member mbr,
int newPstatus,
java.lang.String note)
Create/Update a WFNote and check if the transition can be performed.
|
Publication |
createWorkCopy(Member mbr)
Creates a work copy for this publication
|
void |
discardCopy(Publication copy)
This method is called when the creation of copy or a work copy of this publication has failed.
|
void |
exportXmlField(java.lang.StringBuffer sb,
int indentLevel)
Fills the given StringBuffer with Xml export of fields of this data.
|
java.lang.String |
getAbstract()
Returns the abstract of this publication in the channel's main language.
|
java.lang.String |
getAbstract(java.lang.String lang)
Returns the abstract of this publication.
|
java.lang.String |
getAbstract(java.lang.String lang,
boolean useDefault)
Returns the abstract of this publication.
|
java.util.HashMap<java.lang.String,java.lang.String> |
getAbstractML()
Returns the map containing abstracts of this publication in all language but the channel's main language.
|
int |
getAccessCount() |
java.util.Date |
getAdate()
Retrieve the archiving date of this publication.
|
static <T extends Publication> |
getAdateComparator() |
static Publication.AdateSelector |
getAdateSelector(java.util.Date begin,
java.util.Date end) |
java.util.Set<java.lang.String> |
getAllCatIdSet()
Do not call this method.
|
java.util.Set<java.lang.String> |
getAllFilePath()
Gives the set of all relatives path to all kind (image, media, file) of files linked
from the given publication.
|
java.lang.String |
getAllWikiText()
Returns a String which contains the concatenation of all the wiki fields.
|
java.lang.String |
getAllWysiwygText()
Returns a String which contains the concatenation of all the wysiwyg fields.
|
java.lang.String |
getAudiencedRightsString(java.lang.String userLang,
int max)
This convenient method returns a String displaying categories
used by audience right (eg if this publication is restricted to member, g2,
m1, m2 and m3, getReadRightsString(3) will return
"g1, g2, m1, ...")
|
static <T extends Publication> |
getAudienceRightComparator() |
static Publication.AudienceRightSelector |
getAudienceRightSelector() |
java.util.Set<java.lang.String> |
getAuthGrpIdSet()
Do not call this method.
|
java.util.Set<java.lang.String> |
getAuthMbrIdSet()
Do not call this method.
|
java.util.Set<Group> |
getAuthorizedGroupSet()
Get the set of Group authorized to read this Publication.
|
java.util.Set<Member> |
getAuthorizedMemberSet()
Get the set of Member authorized to read this Publication.
|
static Publication.AuthorizedSelector |
getAuthorizedSelector(Member member) |
static Publication.CanWorkOnSelector |
getCanWorkOnSelector(Member member) |
Category[] |
getCategories()
Retrieve the categories of this publication.
|
Category[] |
getCategories(Member member)
Returns the categories of the publication the member can read
|
java.util.TreeSet<Category> |
getCategorySet()
Returns the categories of this publication as a Set.
|
java.util.Set<java.lang.String> |
getCatIdSet()
Do not call this method.
|
static <T extends Publication> |
getComparator(java.lang.Class<T> clazz,
java.lang.String str,
boolean reverse)
Deprecated.
|
static java.util.Comparator |
getComparator(java.lang.String str,
boolean reverse)
Deprecated.
|
static java.util.Comparator |
getComparator(java.lang.String str,
boolean reverse,
QueryResultSet queryResultSet)
Deprecated.
|
static java.lang.String |
getCSVHeader(java.lang.String lang)
Returns the CSV header of this object
|
java.lang.String |
getDataIcon()
Returns source information for the icon associated to this Data, either a relative path or sprite classes name.
|
java.lang.String |
getDataIconTitle(java.lang.String lang)
Returns the icon's tooltip.
|
java.lang.String |
getDataName(java.lang.String language)
Return the name of this Data, every sub class Data which will be displayed to user should
implements this method already.
|
java.util.Date |
getDate(java.lang.String dateType)
Return the date corresponding to the given parameter :
date/cdate, mdate, edate, pdate, sdate, adate, udate or null if nothing
match or the matching date is null.
|
java.util.Date |
getDate(java.lang.String dateType,
java.util.Date defaultDate)
Return the date corresponding to the given parameter :
date/cdate, mdate, edate, pdate, sdate, adate, udate, or null if nothing
match or the matching date is null.
|
static DataSelector |
getDateSelector(java.lang.String str,
java.util.Date begin,
java.util.Date end)
Retrieves a new
DataSelector given a name representing
it. |
DBDataRevision |
getDBDataRevision(Data data,
int op) |
static <T extends Publication> |
getDdateComparator() |
java.lang.String |
getDefaultTemplateUsage()
Returns the default template usage used to display the publication.
|
java.util.TreeSet<Category> |
getDescendantCategorySet(Category parent)
Return the set of category of this publication which are the
descendant category of a given parent category.
|
java.util.TreeSet<Category> |
getDescendantCategorySet(Category parent,
boolean includingParent)
Return the set of category of this publication which are the
descendant category of a given parent category, including the given
parent category in case the parameter
includingParent is true. |
java.util.TreeSet<Category> |
getDescendantCategorySet(Category parent,
boolean includingParent,
Member member)
Return the set of category of this publication which are the
descendant category of a given parent category, including the
given parent category in case the parameter
includingParent is true. |
java.lang.String |
getDisplayTemplateFile()
Deprecated.
Must call instead getTemplatePath()
|
java.util.Set<FileDocument> |
getDocumentLinkSet()
Returns the set of documents attached to this publication.
|
java.util.Date |
getEdate()
Retrieve the expiration date of this publication.
|
static <T extends Publication> |
getEdateComparator() |
static Publication.EdateSelector |
getEdateSelector(java.util.Date begin,
java.util.Date end) |
int |
getEstimatedReminderCount()
Returns an estimation of how many reminders have been sent since this publication is in this state.
|
java.util.Set<java.lang.String> |
getExternalLinkSet()
Returns all the external link contains in this publication.
|
java.lang.Object |
getFieldInMainLanguage(java.lang.Object field,
java.util.HashMap fieldML) |
java.lang.Object |
getFieldValue(java.lang.String fieldName,
java.lang.String lang,
boolean useDefault)
Gets the value of the given
Object field name for the current Data . |
Category |
getFirstDescendantCategory(Category parent)
This convenient method returns the first category of the set
returned by getDescendantCategorySet.
|
Category |
getFirstDescendantCategory(Category parent,
boolean includingParent)
This convenient method returns the first category of the set
returned by getDescendantCategorySet, including the parent in
case parameter
includingParent is true and the
current publication has parent as category. |
Category |
getFirstDescendantCategory(Category parent,
boolean includingParent,
Member member)
This convenient method returns the first category of the set
returned by getDescendantCategorySet, including the parent in case parameter
includingParent is true and the current publication has parent as category. |
java.util.List<Member> |
getFollowerList(boolean searchParents)
Returns all the followers of this publication.
|
java.util.TreeSet<java.lang.String> |
getFriendlyURLSet()
Get friendly urls Set.
|
boolean |
getHasNoReadRights()
Do not call this method.
|
Publication |
getImportConflictCopy()
Returns the conflict copy bound to this imported publication (or null if there is no conflict copy).
|
java.lang.String |
getImportVersion()
Get the value of importVersion.
|
java.util.Date |
getIndexingDate()
Retrieve the Date at which this Publication was indexed in its search engine.
|
Workflow |
getInternalWorkflow()
Returns the Workflow bound internaly to this publication
|
java.util.TreeSet |
getLinkDataSet(java.lang.Class clazz)
Retuns all the data, instance of a given class, targeted by this
publication through its link field (ie the link defined with
the Type Editor.
|
Publication |
getMainInstance()
If this publication is a work copy then return the main instance
|
java.lang.String |
getMainLanguage()
Get the value of main language.
|
int |
getMajorVersion()
Returns the major version.
|
java.util.TreeSet<Member> |
getMemberSetAssignedToRole(java.lang.String roleId)
Returns the member bound to the given role.
|
java.util.Date |
getMergeDate()
Returns the date of the last merge with a work copy.
|
java.lang.String |
getMergeId()
Returns the id of the work copy used for the last merge.
|
int |
getMinorVersion()
Returns the minor version.
|
java.util.Set<WFState> |
getNextWFStateSet(Member member)
Returns the set of WFState the given member can put this publication in,
according the rights of the member, the workflow and the current state of the publication.
|
java.util.Date |
getPdate()
Retrieve the publication date of this publication.
|
static <T extends Publication> |
getPdateComparator() |
static Publication.PdateSelector |
getPdateSelector(java.util.Date begin,
java.util.Date end) |
int |
getPopularity() |
static <T extends Publication> |
getPopularityComparator() |
int |
getPstatus()
Get the value of pstatus.
|
AlarmEntry |
getPstatusAlarmEntry(int pstatus)
Get the alarmEntry bound to a given pstatus
|
static <T extends Publication> |
getPstatusComparator() |
static Publication.PstatusSelector |
getPstatusSelector(int pstatus) |
static Publication.PstatusSelector |
getPstatusSelector(int pstatus,
int greater) |
java.lang.String |
getQueryTemplateFile()
Deprecated.
Must call instead getTemplatePath()
|
static <T extends Publication> |
getReaderComparator() |
int |
getReaderCount() |
java.util.List<ReaderTracker> |
getReaderTrackerList()
Returns the reader list for the given publication.
|
static Publication.ReadRightSelector |
getReadRightSelector() |
java.lang.String |
getReadRightsString(int max)
This convenient method returns a String displaying group/member
read rights (eg if this publication is restricted to g1, g2,
m1, m2 and m3, getReadRightsString(3) will return
"g1, g2, m1, ...")
|
static <T extends Publication> |
getRightComparator() |
java.util.HashMap<java.lang.String,java.util.TreeSet<Member>> |
getRoleMap() |
java.lang.String |
getRoleMapStr()
Returns the encoded String from the current roleMap (only used for DBData property mapping)
|
java.util.Date |
getSdate()
Retrieve the sort date of this publication.
|
static <T extends Publication> |
getSdateComparator() |
static Publication.SdateSelector |
getSdateSelector(java.util.Date begin,
java.util.Date end) |
java.lang.String[] |
getSearchStrings()
Searchable implementation
|
java.lang.String |
getTemplate(java.lang.String usage)
Returns the template name for the given usage
|
TypeTemplateEntry |
getTemplateEntry(java.lang.String usage,
boolean devModeChecks)
Returns the TypeTemplateEntry matching the given parameters.
|
static TypeTemplateEntry |
getTemplateEntry(java.lang.String usage,
boolean devModeChecks,
java.lang.Class<? extends Data> clazz,
Workspace ws)
Returns the TypeTemplateEntry matching the given parameters.
|
java.util.Set<TypeTemplateEntry> |
getTemplateEntrySet()
Returns a Set of TypeTemplateEntry matching current publication templates
|
java.lang.String |
getTemplatePath(JcmsJspContext ctxt)
Returns the template path for the current context
|
java.lang.String |
getTemplatePath(java.lang.String usage,
boolean devModeChecks)
Returns the template path for the given usage
|
java.lang.String[] |
getTemplates()
Get the value of templates.
|
java.lang.String |
getTitle()
Retrieve the title of this publication in the main site language.
|
java.lang.String |
getTitle(java.lang.String lang)
Get the value of title bound to the given language.
|
java.lang.String |
getTitle(java.lang.String lang,
boolean useDefault)
Get the value of title bound to the given language.
|
static <T extends Publication> |
getTitleComparator() |
static <T extends Publication> |
getTitleComparator(java.lang.String lang) |
java.util.HashMap<java.lang.String,java.lang.String> |
getTitleML()
Retrieve the HashMap containing the titles of this publication in
language other than the main site language.
|
static Publication.TrackedSelector |
getTrackedSelector() |
java.util.Collection<? extends TreeNode> |
getTreeChildren()
Returns a Collection of TreeNode children
of the current node
|
TreeNode |
getTreeParent()
Returns parent of the current node
|
TreeNode |
getTreeRoot()
Returns the root of the current node
|
static <T extends Publication> |
getTypeComparator() |
java.lang.String |
getTypeLabel(java.lang.String lang)
Returns the label of the type of this publication.
|
java.util.Date |
getUdate()
Returns the date of last major update.
|
static <T extends Publication> |
getUdateComparator() |
static Publication.UdateSelector |
getUdateSelector(java.util.Date begin,
java.util.Date end) |
java.util.Set<Group> |
getUpdateGroupSet()
Get the value of updateGroupSet.
|
java.util.Set<Member> |
getUpdateMemberSet()
Get the value of updateMemberSet.
|
java.lang.String |
getVersionString()
Returns the current version (major.minor) of this publication.
|
static Publication.VisibleStateSelector |
getVisibleStateSelector() |
int |
getVoteCount() |
int |
getVoteScore() |
static <T extends Publication> |
getVoteScoreComparator() |
int |
getVoteValue() |
java.util.Set<Publication> |
getWeakReferrerSet()
Returns the set of weak referrers.
|
java.util.List<WFNote> |
getWFNoteList()
Returns the list of WFNote bound to this publication.
|
WFState |
getWFState()
Returns the WFState bound to the current pstatus or null if none
|
java.lang.String |
getWFStateLabel(java.lang.String lang)
This convenient method returns the Workflow's state label this
publication is in.
|
java.lang.String |
getWFStateLabelHtml(java.lang.String lang)
This convenient method returns the HTML Workflow's state label this
publication is in.
|
java.util.Set<Publication> |
getWorkCopySet()
Get the value of workCopySet.
|
Workflow |
getWorkflow()
Returns the Workflow bound to this publication
|
java.lang.String |
getWorkflowId()
Returns the internal workflow id if set (only worklow instance, not workflow associated with the publication class)
|
Workspace |
getWorkspace() |
static Publication.WorkspaceAuthorSelector |
getWorkspaceAuthorSelector(Workspace workspace,
Member author) |
static <T extends Publication> |
getWorkspaceComparator(java.lang.String lang) |
java.lang.String |
getWorkspaceId()
Returns the JStore ID of the workspace (only for DBData)
|
static Publication.WorkspaceSelector |
getWorkspaceSelector(Workspace workspace) |
WSTypeEntry |
getWSTypeEntry()
This method return a WSTypeEntry for the current workspace
in the current class.
|
WSTypeEntry |
getWSTypeEntry(Workspace wrkspc)
This method return a WSTypeEntry for the given workspace
in the current class.
|
boolean |
hasAlreadyVoted(Member member)
Check if the given member has already voted for this publication
|
boolean |
hasAnyReadRights()
Tests if this publication has member or group read rights.
|
boolean |
hasBeenReadBy(Member mbr)
Check if the given member has read this publication
|
boolean |
hasCategory(Category cat)
Test if a publication references a given category.
|
boolean |
hasImportConflict()
Returns true if this imported publication has a conflict copy.
|
boolean |
hasNoReadRights()
Tests if this publication has NO member read rights AND NO group
read rights.
|
boolean |
hasWeakReferrers()
Returns true if this publication has weak referrers.
|
void |
importConvertToLocal(Member opAuthor)
Converts this imported publication to a local data
|
void |
importMarkAsMerged(Member opAuthor)
Merges all the import extra data (import date, import version, ....) of the most recent
conflict copy with the original.
|
void |
importOverrideAndUpdate(Member opAuthor)
Ignores all the local changes and replaces the local imported data with the conflict copy.
|
void |
importXml(org.jdom.Element elt,
ImportOptions options)
Fill this data with the values contains in the JDOM element.
|
void |
init(Member author,
Workspace ws)
This method initialise the object with default values for the given workspace:
Default categories
Default Authorized groups
Default Pstatus
Given Workspace
Given Author and opAuthor
It should be called after constructor and before setting parameters.
|
void |
initCopy(Member newAuthor)
Initialize this publication once it has been cloned for a copy
(eg by duplicate.jsp)
|
void |
initializeDBDataCollections()
This methods force the collections of the DBData to be initialized()
|
protected boolean |
internalCanBeReadBy(Member member,
boolean searchInGroups,
RightInfo rightInfo) |
boolean |
isAudienced()
Check if this publication is Audienced.
|
boolean |
isDefaultTemplate(java.lang.String usage)
Checks if the publication use a default template for the given usage
|
boolean |
isFollowedBy(Member mbr)
Returns true if the given member follows this publication.
|
boolean |
isImportConflictCopy()
Returns true if this publication is an import conflict copy.
|
boolean |
isInRole(java.lang.String roleId,
Member mbr)
Determines whether the given member can use the given role for this publication
|
boolean |
isInVisibleState()
Returns true if this publication is in a visible state
|
boolean |
isPublic()
Returns true is this publication can be read by any one.
|
boolean |
isRoleAssigned(java.lang.String roleId)
Determines whether there exists at least one member assigned to the given role
|
boolean |
isTracked()
Check if a the publication's readers are tracked
|
boolean |
isTreeLeaf()
Returns boolean true if the TreeNode is a leaf
|
boolean |
isTreeNode()
Returns boolean true if the TreeNode is a node
|
boolean |
isUserContent()
Returns true if this data is User Content.
|
static boolean |
isUserContentType(java.lang.Class<?> clazz)
Checks if the given class is a "User Content"
That means a Publication not manage by JCMS workers.
|
boolean |
isVersioned()
Returns true if the current Publication is versioned (is stored or is instance of HistorizedDBData)
|
boolean |
isVotable() |
boolean |
isWorkCopy()
Return true if this publication have a main instance
|
void |
majorUpdate()
Increments the major version
|
void |
notifyFollowers(Member opAuthor,
java.util.Map context)
Notify all the follower of this publication.
|
protected void |
performAfterWrite(int op,
Member mbr,
java.util.Map context)
Called to perform some action after the write.
|
protected void |
performBeforeWrite(int op,
Member mbr,
java.util.Map context)
Called to perform some action before the write.
|
void |
performCreate(Member mbr,
java.util.Map context)
Performs data creation
|
void |
performDelete(Member mbr,
java.util.Map context)
Performs data deletion
|
void |
performMerge(Member mbr)
Performs publication merge
|
void |
performMerge(Member mbr,
java.util.Map context)
Performs publication merge
|
void |
performUpdate(Member mbr,
java.util.Map context)
Performs data update
|
protected Publication |
prepareMergeCopy() |
void |
putPstatusAlarmEntry(int pstatus,
AlarmEntry alarmEntry)
Bind an AlarmEntry to a given pstatus
|
void |
recomputeScore()
Recompute the score of the publication
|
void |
removeAllDescendants(Member opAuthor,
java.util.Map context)
Remove all descendant TreeNode that can be deleted
|
void |
removeAllFollowers()
Removes all the follower for this publication.
|
void |
removeAllReaderTracker(Member opAuthor)
Remove all the readers notes
|
boolean |
removeAuthorizedGroup(Group grp)
Remove an authorized group.
|
boolean |
removeAuthorizedMember(Member mbr)
Remove an authorized member.
|
void |
removeCategory(Category cat)
Remove the specified category from this publication's categories
|
protected void |
removeDataSet(Member opAuthor,
java.util.Set<? extends Data> dataSet)
Remove all the data of the given data set
|
void |
removeFollower(Member mbr)
Removes the given follower for this publication.
|
void |
removeImportMetadata()
Remove all the import metadata on this publication
|
AlarmEntry |
removePstatusAlarmEntry(int pstatus)
Remove an AlarmEntry to a given pstatus
|
void |
removeWeakReferrer(Publication referrer)
Remove a weak referrer.
|
void |
removeWFExpressAlarm()
Removes the WFExpress alarm for this publication.
|
void |
removeWFReminderAlarm()
Removes the WFExpress alarm for this publication.
|
protected static TypeTemplateEntry |
resolveTypeTemplateEntry(WSTypeEntry wste,
java.lang.String usage,
java.lang.String[] templates)
Returns TypeTemplateEntry matching given parameters.
|
void |
setAbstract(java.lang.String value)
Set the value of the Abstract field in the main language (default site language or any other).
|
void |
setAbstract(java.lang.String lang,
java.lang.String value)
Convenient method to set the value of the Abstract field
in any language (default site language or any other).
|
void |
setAdate(java.util.Date v)
Set the archiving date of this publication.
|
void |
setAllCatIdSet(java.util.Set<java.lang.String> v)
Do not call this method.
|
void |
setAuthGrpIdSet(java.util.Set<java.lang.String> v)
Do not call this method.
|
void |
setAuthMbrIdSet(java.util.Set<java.lang.String> v)
Do not call this method.
|
void |
setAuthorizedGroupSet(java.util.TreeSet<Group> groupSet)
Set the set of Group authorized to read this Publication.
|
void |
setAuthorizedMemberSet(java.util.TreeSet<Member> memberSet)
Set the set of Member authorized to read this Publication.
|
void |
setCategories(Category[] cats)
Set categories of this publication.
|
void |
setCategorySet(java.util.Set<Category> catSet)
Replaces the current categories with this set of categories.
|
void |
setCatIdSet(java.util.Set<java.lang.String> v)
Do not call this method.
|
void |
setCdate(java.util.Date cdate)
Set the cdate and update the udate
|
void |
setEdate(java.util.Date v)
Set the expiration date of this publication.
|
void |
setFieldValue(java.lang.String fieldName,
java.lang.Object value,
java.lang.String lang)
Sets the value of the given
Object field name for the current Data . |
void |
setFriendlyURLSet(java.util.TreeSet<java.lang.String> v)
Set the value of friendlyURLSet.
|
void |
setHasNoReadRights(boolean b)
Do not call this method.
|
void |
setImportConflictCopy(boolean v)
Set the value of isImportConflictCopy.
|
void |
setImportVersion(java.lang.String v)
Set the value of importVersion.
|
void |
setMainInstance(Publication mainInstance)
If this publication is a work copy then set it's main instance
|
void |
setMainLanguage(java.lang.String v)
Set the value of main language.
|
void |
setMajorVersion(int majorVersion)
Set the major version.
|
void |
setMergeDate(java.util.Date mergeDate)
Set the date of the last merge with a work copy
|
void |
setMergeId(java.lang.String mergeId)
Set the id of the work copy used for the last merge.
|
void |
setMinorVersion(int minorVersion)
Set the minor version.
|
void |
setPdate(java.util.Date v)
Set the publication date of this publication.
|
void |
setPstatus(int v)
Set the value of pstatus.
|
void |
setReaderCount(int v)
Do not call this method.
|
void |
setRoleMap(java.util.HashMap<java.lang.String,java.lang.Object> roleMap) |
void |
setRoleMapStr(java.lang.String str)
Assigns the roleMap from the given encoded String (only used for DBData property mapping)
|
void |
setRoleMemberSetMap(java.util.HashMap<java.lang.String,java.util.TreeSet<Member>> roleMap) |
void |
setSdate(java.util.Date v)
Set the sort date of this publication.
|
void |
setTemplate(java.lang.String name) |
void |
setTemplates(java.lang.String[] v)
Set the value of templates.
|
void |
setTitle(java.lang.String v)
Set the title of this publication in the main site language.
|
void |
setTitle(java.lang.String lang,
java.lang.String value)
Convenient method to set the value of the Title field
in any language (default site language or any other).
|
void |
setTitleML(java.util.HashMap<java.lang.String,java.lang.String> v)
Set the HashMap containing the titles of this publication in
language other than the main site language.
|
void |
setTracked(boolean bool)
Set the track flag
|
void |
setUdate(java.util.Date udate)
Set the date of last major update.
|
void |
setUpdateGroupSet(java.util.TreeSet<Group> v)
Set the value of updateGroupSet.
|
void |
setUpdateMemberSet(java.util.TreeSet<Member> v)
Set the value of updateMemberSet.
|
void |
setVoteCount(java.lang.Integer voteCount) |
void |
setVoteScore(java.lang.Integer voteScore) |
void |
setWorkflow(Workflow workflow) |
void |
setWorkflowId(java.lang.String wfId)
set the internal workflow id (if the id is null, workflow will be workflow associated with publication class)
|
void |
setWorkspace(Workspace workspace) |
void |
setWorkspaceId(java.lang.String v)
Sets the JStore ID of the workspace (only for DBData)
|
java.lang.String |
toCSV(java.lang.String lang)
Returns a CSV view of this object
|
java.lang.String |
toFullString() |
java.lang.String |
toString() |
void |
trackReader(Member mbr)
Track the given reader.
|
void |
trackReader(Member mbr,
int accessType)
Track the given reader for given access type.
|
void |
unassignMember(Member mbr)
Unassign a member from all the role he has been assigned to.
|
void |
unassignRole(java.lang.String roleId)
Unassigns a member to a role
|
void |
updatePstatus(Member author,
int newPstatus,
java.lang.String note)
Change the pstatus of this publication, store it and generate a WFNote
|
protected java.lang.String[] |
updateTemplate(java.lang.String name,
java.lang.String[] templates) |
checkCreate, checkDelete, checkIntegrity, checkLockMember, checkStrongLockMember, checkUpdate, clone, computeDBIDArray, exportXml, exportXml, exportXml, exportXml, exportXmlRelated, exportXmlRelated, fillExportXmlFieldAttributes, getAllReferrerSet, getAllReferrerSet, getAllTypeFieldEntry, getAuthor, getAuthor, getAuthorComparator, getAuthorDBID, getAuthorId, getAuthorSelector, getBooleanFieldValue, getBooleanFieldValue, getCaddyComparator, getCategoryFieldValue, getCategoryFieldValue, getCdateSelector, getDataIconAlt, getDataIconHtml, getDataIconHtml, getDataImage, getDataImage, getDataImage, getDataNameComparator, getDeletableSelector, getDisplayLink, getDisplayLink, getDisplayLink, getDisplayUrl, getDoubleFieldValue, getDoubleFieldValue, getExportXmlDataValue, getExtension, getExtraData, getExtraDataMap, getExtraDBData, getExtraDBDataMap, getExtraInfo, getExtraInfoMap, getFieldStatusMap, getFieldValue, getFieldValue, getFieldValue, getGenericThumbnail, getImportAuthor, getImportBatch, getImportDate, getImportDisplayUrl, getImportId, getImportMap, getImportMdate, getImportSelector, getImportSignature, getImportSource, getImportSourceUrl, getImportUrl, getIntFieldValue, getIntFieldValue, getLangPropertyValue, getLinkCount, getLinkIndexedDataSet, getLinkIndexedDataSet, getLockDate, getLockInfo, getLockMember, getLongFieldValue, getLongFieldValue, getMdateSelector, getNewDefaultExtraDataMap, getNewDefaultExtraDataMap, getNewDefaultExtraDataMap, getNewDefaultExtraDataMap, getNewDefaultExtraDBDataMap, getNewDefaultExtraDBDataMap, getNewDefaultExtraDBDataMap, getNewDefaultExtraDBDataMap, getOpAuthor, getOpAuthorComparator, getOpDelegate, getRowId, getRowIdComparator, getStrongLock, getStrongLockDate, getStrongLockInfo, getStrongLockMember, getStrongLockSelector, getTypeEntry, getTypeFieldsEntries, getUpdateInstance, getVirtualIDSet, hashCode, importXmlFieldsWithReferences, importXmlFiles, importXmlReferences, isDBData, isImported, isImportUpdated, isInDatabase, isLocked, isPersisted, isStrongLocked, lock, markNewImport, mergeHybridLink, performCreate, performDelete, performUpdate, prepareUpdateContext, printDataName, printDisplayLinkEnd, printDisplayLinkStart, printDisplayUrl, printDisplayUrl, putStrongLock, releaseStrongLock, releaseStrongLock, removeExtraData, removeExtraDBData, removeExtraInfo, setAuthor, setAuthorDBID, setAuthorId, setBooleanFieldValue, setCategoryFieldValue, setDoubleFieldValue, setExtension, setExtraData, setExtraDataMap, setExtraDBData, setExtraDBDataMap, setExtraDBDataMap, setExtraInfo, setFieldValue, setId, setImportAuthor, setImportBatch, setImportDate, setImportDisplayUrl, setImportId, setImportMap, setImportMdate, setImportSignature, setImportSource, setImportSourceUrl, setImportUpdated, setIntFieldValue, setLongFieldValue, setMdate, setOpAuthor, setOpDelegate, setRowId, unlock, unlock, unmarkNewImport, updateExtraDataMap, updateExtraDBDataMap, updateIndexTreeSet
clearId, compareTo, equals, getAttribute, getAttributes, getCdate, getCdateComparator, getDdate, getId, getIdComparator, getMdate, getMdateComparator, getStore, getUrid, hasBeenUpdated, isStored, resolveAtt, resolveVal, setAttributes, setAttributes, setDdate, setStore, toXml
public static final java.lang.String PUBLICATION_WFNOTE
public static final java.lang.String REVISION
public static final int CTRL_TOPIC_CATEGORIES
public static final int CTRL_TOPIC_WORKFLOW
public static final int CTRL_TOPIC_ADVANCED
protected static PublicationIndexManager indexMgr
protected java.lang.String mainLanguage
protected java.lang.String title
protected java.util.HashMap<java.lang.String,java.lang.String> titleML
protected java.util.Date pdate
protected java.util.Date edate
protected java.util.Date sdate
protected java.util.Date adate
protected java.util.Date udate
protected int majorVersion
protected transient int minorVersion
protected int pstatus
protected java.util.Date mergeDate
protected java.lang.String mergeId
protected Category[] categories
protected java.lang.String[] templates
protected java.util.TreeSet<Member> authorizedMemberSet
protected java.util.TreeSet<Group> authorizedGroupSet
protected java.util.TreeSet<Member> updateMemberSet
protected java.util.TreeSet<Group> updateGroupSet
protected Publication mainInstance
protected boolean isTracked
protected java.util.TreeSet<java.lang.String> friendlyURLSet
protected Workspace workspace
protected java.util.HashMap<java.lang.String,java.util.TreeSet<Member>> roleMap
protected java.lang.String workflowId
protected transient java.util.TreeSet<Category> categorySet
protected transient AlarmEntry wfExpressAlarmEntry
protected transient AlarmEntry wfReminderAlarmEntry
protected transient java.util.Set<java.lang.String> catIdSet
protected transient boolean catIdSetDirty
protected transient boolean catIdSetInit
protected transient java.util.Set<java.lang.String> allCatIdSet
protected transient java.util.Set<java.lang.String> authMbrIdSet
protected transient boolean authMbrIdSetDirty
protected transient boolean authMbrIdSetInit
protected transient java.util.Set<java.lang.String> authGrpIdSet
protected transient boolean authGrpIdSetDirty
protected transient boolean authGrpIdSetInit
protected transient boolean hasNoReadRightsDBData
protected transient int readerCount
protected transient int voteScore
protected transient int voteCount
public Publication()
public Publication(Publication other)
public void init(Member author, Workspace ws)
This method initialise the object with default values for the given workspace:
It should be called after constructor and before setting parameters. Handlers already set theses parameters. This is a convenient method for external developpements.
author
- the Author of the publicationws
- the workspace of the publicationpublic java.lang.String getAllWikiText()
public java.lang.String getAllWysiwygText()
public java.lang.String[] getSearchStrings()
getSearchStrings
in interface Searchable
Searchable.getSearchStrings()
public boolean hasCategory(Category cat)
cat
- the category to be testedpublic java.lang.String toString()
public void importXml(org.jdom.Element elt, ImportOptions options)
Data
public Publication getImportConflictCopy()
public boolean hasImportConflict()
public boolean isImportConflictCopy()
public void setImportConflictCopy(boolean v)
v
- Value to assign to isImportConflictCopy.public void importMarkAsMerged(Member opAuthor)
opAuthor
- the author of the operationpublic void importOverrideAndUpdate(Member opAuthor)
opAuthor
- the author of the operation.public void importConvertToLocal(Member opAuthor)
opAuthor
- the author of the operationpublic void removeImportMetadata()
@Deprecated public java.lang.String computeSignature()
computeSignature(boolean, boolean)
public java.lang.String computeSignature(boolean includePublicationFields, boolean hash)
includePublicationFields
- if true add the common publication fields (author, pdate, categories, ...). Computed fields (cdate, mdate, udate, minorVersion) are skipped.hash
- if true hash (MD5) the signature otherwise return the complete string of the signature.public void exportXmlField(java.lang.StringBuffer sb, int indentLevel)
Data
exportXmlField
in class Data
sb
- the StringBufferindentLevel
- the indent levelpublic java.util.Set<FileDocument> getDocumentLinkSet()
public java.util.Set<java.lang.String> getAllFilePath()
public java.lang.String getTypeLabel(java.lang.String lang)
lang
- the languagepublic java.lang.String getVersionString()
public void majorUpdate()
public java.lang.String toFullString()
toFullString
in class Data
public java.lang.String toCSV(java.lang.String lang)
public static java.lang.String getCSVHeader(java.lang.String lang)
lang
- the output languagepublic java.lang.String getAbstract()
public java.lang.String getAbstract(java.lang.String lang, boolean useDefault)
lang
- the user language (ISO-639 language code)useDefault
- should the default language be usedpublic java.lang.String getAbstract(java.lang.String lang)
lang
- the user languagepublic java.util.HashMap<java.lang.String,java.lang.String> getAbstractML()
public void setAbstract(java.lang.String lang, java.lang.String value)
lang
- the language (ISO 639 code) in which to set the valuevalue
- the value to set.public void setAbstract(java.lang.String value)
value
- the value to set.public void clearTransientIndex()
public void setWorkflow(Workflow workflow)
public void initCopy(Member newAuthor)
newAuthor
- the author of this publicationpublic void discardCopy(Publication copy)
copy
- the copy which has been discarded.public Publication createCopy(Member mbr)
mbr
- the author of the copypublic Publication createWorkCopy(Member mbr)
mbr
- the author of the work copypublic java.util.TreeSet<Category> getDescendantCategorySet(Category parent)
parent
- the parent categorypublic java.util.TreeSet<Category> getDescendantCategorySet(Category parent, boolean includingParent)
includingParent
is true.
The set is ordered according the Category.OrderComparator. This methods only
returns public categories (ie without read rights).parent
- the parent categoryincludingParent
- true if the parent has to be included in the set of tested categoriespublic java.util.TreeSet<Category> getDescendantCategorySet(Category parent, boolean includingParent, Member member)
includingParent
is true. Check category read rights
for the given member. The set is ordered according the
Category.OrderComparator using current userLang (see Channel.getCurrentUserLang()
.parent
- the parent categoryincludingParent
- true if the parent has to be included in the set of tested categoriesmember
- if not null, checks if the category read rights for this memberpublic Category getFirstDescendantCategory(Category parent)
parent
- the parent categorypublic Category getFirstDescendantCategory(Category parent, boolean includingParent)
includingParent
is true and the
current publication has parent
as category. This
methods returns a public category (ie without read rights).parent
- the parent categoryincludingParent
- true if the category membership test must be made on parent toopublic Category getFirstDescendantCategory(Category parent, boolean includingParent, Member member)
includingParent
is true and the current publication has parent
as category. Check category read rights for the given member.parent
- the parent categoryincludingParent
- true if the category membership test must be made on parent toomember
- if not null, checks if the category read rights for this memberpublic boolean containsCategory(Category category)
category
- the categorypublic boolean hasWeakReferrers()
public java.util.Set<Publication> getWeakReferrerSet()
public void addWeakReferrer(Publication referrer)
referrer
- the weak referrer to be added.public void removeWeakReferrer(Publication referrer)
referrer
- the weak referrer to be removed.public java.util.Set<java.lang.String> getExternalLinkSet()
public final boolean canBeReadBy(Member member, boolean searchInGroups)
member
- the member to checksearchInGroups
- if true check if one of the group this
member belongs to is authorized to read this publication.public final boolean canBeReadBy(Member member, boolean searchInGroups, RightInfo rightInfo)
protected boolean internalCanBeReadBy(Member member, boolean searchInGroups, RightInfo rightInfo)
public boolean isUserContent()
public static boolean isUserContentType(java.lang.Class<?> clazz)
clazz
- the working classpublic boolean canBeReadBy(Member member)
member
- the member to checkcanBeReadBy(com.jalios.jcms.Member,boolean)
public boolean canBeReadBy(Group group)
group
- the group to checkpublic boolean isAudienced()
RightPolicy.isAudienced(Publication)
.RightPolicy.isAudienced(Publication)
public java.lang.String getAudiencedRightsString(java.lang.String userLang, int max)
userLang
- the user languagemax
- how many group/member to displaypublic boolean hasAnyReadRights()
public boolean hasNoReadRights()
public boolean getHasNoReadRights()
public void setHasNoReadRights(boolean b)
public java.lang.String getReadRightsString(int max)
The returned string is properly encoded for use in HTML attribute.
max
- how many group/member to displaypublic boolean isPublic()
public Publication getMainInstance()
public void setMainInstance(Publication mainInstance)
mainInstance
- the main instancepublic boolean isWorkCopy()
public boolean isInVisibleState()
Channel.isVisiblePstatus(int)
public ControllerStatus canBeArchived(Member mbr, java.util.Map context)
mbr
- the member to checkcontext
- theCustomArchiveManager.canBeArchived(com.jalios.jcms.Publication, com.jalios.jcms.Member, Map)
public boolean canBeArchived(Member mbr)
mbr
- canBeArchived(Member, Map)
public boolean canCreateCopy(Member mbr)
mbr
- the member to be checkedpublic boolean canCreateCopy(Member mbr, boolean isWorkCopy)
mbr
- the member to be checkedisWorkCopy
- true if this is a workCopypublic boolean canCreateWorkCopy(Member mbr)
mbr
- the member to be checkedpublic boolean canMergeWorkCopy(Member mbr)
mbr
- the member to be checkedpublic boolean canBeEditedFieldByField(Member mbr)
mbr
- the member to checkpublic boolean canRequestUnlock(Member mbr)
Data
canRequestUnlock
in class Data
mbr
- the member who request the lockpublic Workflow getInternalWorkflow()
public java.lang.String getWorkflowId()
public void setWorkflowId(java.lang.String wfId)
public Workflow getWorkflow()
public WFState getWFState()
public java.lang.String getWFStateLabel(java.lang.String lang)
lang
- the language used for localisation.getWFState()
public java.lang.String getWFStateLabelHtml(java.lang.String lang)
lang
- public java.util.Set<WFState> getNextWFStateSet(Member member)
member
- the member.public AlarmEntry getPstatusAlarmEntry(int pstatus)
pstatus
- the pstatuspublic void putPstatusAlarmEntry(int pstatus, AlarmEntry alarmEntry)
pstatus
- the pstatusalarmEntry
- the AlarmEntrypublic AlarmEntry removePstatusAlarmEntry(int pstatus)
pstatus
- the pstatuspublic java.util.TreeSet getLinkDataSet(java.lang.Class clazz)
clazz
- the class of Datapublic boolean checkLang(java.lang.String lang)
lang
- the language to check (lower-case two-letter codes as
defined by ISO-639 (eg: en, fr, de, es, ...)public Category[] getCategories(Member member)
member
- the member to be checkedpublic java.util.TreeSet<Category> getCategorySet()
Do not modify the returned value !! This method returns an internal index which is not stored. If you need to modify the categories of this publication, see methods setCategories(Category[])
, addCategory(Category)
or
removeCategory(Category)
.
This methods always returns a set with the exact same categories available through getCategories()
.
public void setCategorySet(java.util.Set<Category> catSet)
catSet
- the new category setpublic void addCategory(Category cat)
cat
- the category to be addedpublic void removeCategory(Category cat)
cat
- the category to be removedpublic void updatePstatus(Member author, int newPstatus, java.lang.String note)
author
- the author of this update (ie the author of the WFNote)newPstatus
- new value of pstatusnote
- the WFNote's commentpublic WSTypeEntry getWSTypeEntry(Workspace wrkspc)
wrkspc
- The working WorkspaceWorkspace.getWSTypeEntry(Class)
public WSTypeEntry getWSTypeEntry()
getWSTypeEntry(Workspace)
@Deprecated public java.lang.String getDisplayTemplateFile()
@Deprecated public java.lang.String getQueryTemplateFile()
public java.lang.String getDefaultTemplateUsage()
public boolean isDefaultTemplate(java.lang.String usage)
usage
- the template usagepublic java.lang.String getTemplate(java.lang.String usage)
usage
- the template usagepublic java.lang.String getTemplatePath(JcmsJspContext ctxt)
ctxt
- the JcmsJspContextpublic java.lang.String getTemplatePath(java.lang.String usage, boolean devModeChecks)
usage
- the template usagedevModeChecks
- perform developpement checks on templatepublic TypeTemplateEntry getTemplateEntry(java.lang.String usage, boolean devModeChecks)
usage
- the template usagedevModeChecks
- perform developpement checks on templatepublic static TypeTemplateEntry getTemplateEntry(java.lang.String usage, boolean devModeChecks, java.lang.Class<? extends Data> clazz, Workspace ws)
usage
- the template usagedevModeChecks
- perform developpement checks on templateclazz
- the template publication classws
- the workspace where to create the publicationprotected static TypeTemplateEntry resolveTypeTemplateEntry(WSTypeEntry wste, java.lang.String usage, java.lang.String[] templates)
wste
- the Type Descriptionusage
- the template usagetemplates
- null or available tempaltesTypeEntry.getFirstTemplateEntry(String, String[])
protected static boolean checkTemplateEntry(TypeTemplateEntry tte, java.lang.String usage, boolean devModeChecks, java.lang.String label)
tte
- the TypeTemplateEntry to checkdevModeChecks
- perform developpement checks on templatelabel
- String use for error messagepublic java.util.Set<TypeTemplateEntry> getTemplateEntrySet()
public java.lang.String[] getTemplates()
public void setTemplates(java.lang.String[] v)
v
- Value to assign to templates.public void setTemplate(java.lang.String name)
protected java.lang.String[] updateTemplate(java.lang.String name, java.lang.String[] templates)
public java.lang.Object getFieldInMainLanguage(java.lang.Object field, java.util.HashMap fieldML)
public java.lang.String getMainLanguage()
public void setMainLanguage(java.lang.String v)
v
- Value to assign to main language.public java.lang.String getDataIcon()
Data
If this method behavior has not been overriden by subclass, the default icon can be declared
using property types.{Type}.icon
, where {Type}
is the short class name of
the type concerned.
types.Article.icon: images/jalios/icon/abstract.gif
types.Article.icon: ss_sprite ss_date
getDataIcon
in class Data
images/jalios/icon/abstract.gif
) or sprite classes name (eg ss_sprite ss_date
).Data.getDataIconHtml(String)
public java.lang.String getDataIconTitle(java.lang.String lang)
Data
If this method behavior has not been overriden by subclass, the default alternative text can be declared
using language property types.{Type}.title
, where {Type}
is the short class name of
the type concerned.
getDataIconTitle
in class Data
lang
- the user language.Data.getDataIconHtml(String)
public java.lang.String getDataName(java.lang.String language)
Data
getDataName
in class Data
language
- the language in which to return the name if multilang available for the data.getTitle(String)
,
Data.getDataName(String)
public java.lang.String getTitle(java.lang.String lang)
lang
- the language to get the titlepublic java.lang.String getTitle(java.lang.String lang, boolean useDefault)
lang
- the language to get the titleuseDefault
- should main language used as default language
if title does not exist in the given languagepublic java.lang.String getTitle()
public void setTitle(java.lang.String v)
v
- value to assign to title.public java.util.HashMap<java.lang.String,java.lang.String> getTitleML()
public void setTitleML(java.util.HashMap<java.lang.String,java.lang.String> v)
v
- an HashMap of String.public void setTitle(java.lang.String lang, java.lang.String value)
setTitle(String)
or setTitleML(HashMap)
)
depending on the specified language.lang
- the language (ISO 639 code) in which to set the valuevalue
- the value to set.public java.util.Date getPdate()
public void setPdate(java.util.Date v)
v
- the Date to assign, can be null.public java.util.Date getEdate()
public void setEdate(java.util.Date v)
v
- the Date to assign, can be null.public java.util.Date getSdate()
public void setSdate(java.util.Date v)
v
- the Date to assign, can be null.public java.util.Date getAdate()
public void setAdate(java.util.Date v)
v
- the Date to assign, can be null.public void setUdate(java.util.Date udate)
udate
- the datepublic java.util.Date getUdate()
public int getPstatus()
public void setPstatus(int v)
v
- Value to assign to pstatus.public boolean isVersioned()
public int getMajorVersion()
public void setMajorVersion(int majorVersion)
majorVersion
- the major versionpublic int getMinorVersion()
public void setMinorVersion(int minorVersion)
minorVersion
- the minor version.public void setCdate(java.util.Date cdate)
setCdate
in interface Storable
setCdate
in class BasicStorable
cdate
- Value to assign to cdate.BasicStorable.setCdate(java.util.Date)
public void setMergeDate(java.util.Date mergeDate)
mergeDate
- the merge date.public java.util.Date getMergeDate()
public void setMergeId(java.lang.String mergeId)
mergeId
- public java.lang.String getMergeId()
public Category[] getCategories()
public void setCategories(Category[] cats)
cats
- an array of Category (can be null or empty).public java.util.Set<java.lang.String> getCatIdSet()
public void setCatIdSet(java.util.Set<java.lang.String> v)
public java.util.Set<java.lang.String> getAllCatIdSet()
public void setAllCatIdSet(java.util.Set<java.lang.String> v)
public int getVoteScore()
public void setVoteScore(java.lang.Integer voteScore)
public int getVoteCount()
public void setVoteCount(java.lang.Integer voteCount)
public int getPopularity()
public int getVoteValue()
public void recomputeScore()
public boolean canBeVotedBy(Member mbr)
mbr
- the Memberpublic boolean isVotable()
public java.util.Set<Publication> getWorkCopySet()
public java.util.Set<Member> getAuthorizedMemberSet()
public void setAuthorizedMemberSet(java.util.TreeSet<Member> memberSet)
memberSet
- a set of Member.public void addAuthorizedMember(Member mbr)
mbr
- the member to be added.public boolean removeAuthorizedMember(Member mbr)
mbr
- the member to be removed.public java.util.Set<java.lang.String> getAuthMbrIdSet()
public void setAuthMbrIdSet(java.util.Set<java.lang.String> v)
public java.util.Set<Group> getAuthorizedGroupSet()
public void setAuthorizedGroupSet(java.util.TreeSet<Group> groupSet)
groupSet
- a set of Group.public void addAuthorizedGroup(Group grp)
grp
- the group to be added.public boolean removeAuthorizedGroup(Group grp)
grp
- the group to be removed.public java.util.Set<java.lang.String> getAuthGrpIdSet()
public void setAuthGrpIdSet(java.util.Set<java.lang.String> v)
public java.util.Set<Member> getUpdateMemberSet()
public void setUpdateMemberSet(java.util.TreeSet<Member> v)
v
- Value to assign to updateMemberSet.public java.util.Set<Group> getUpdateGroupSet()
public void setUpdateGroupSet(java.util.TreeSet<Group> v)
v
- Value to assign to updateGroupSet.public boolean isTracked()
public void setTracked(boolean bool)
bool
- a booleanpublic boolean canBeFollowedBy(Member mbr)
mbr
- the memberpublic void addFollower(Member mbr)
mbr
- the followerpublic void removeFollower(Member mbr)
mbr
- the followerpublic void removeAllFollowers()
public boolean isFollowedBy(Member mbr)
mbr
- the member to testpublic java.util.List<Member> getFollowerList(boolean searchParents)
searchParents
- if true search followers of the (TreeNode) parent of this publicationpublic void notifyFollowers(Member opAuthor, java.util.Map context)
opAuthor
- the member who sets off this notification. This member won't be notified.context
- the contextpublic Workspace getWorkspace()
public void setWorkspace(Workspace workspace)
workspace
- The workspace to set.public java.util.HashMap<java.lang.String,java.util.TreeSet<Member>> getRoleMap()
public void setRoleMap(java.util.HashMap<java.lang.String,java.lang.Object> roleMap)
roleMap
- The roleMap to setpublic void setRoleMemberSetMap(java.util.HashMap<java.lang.String,java.util.TreeSet<Member>> roleMap)
public void setRoleMapStr(java.lang.String str)
str
- the encoded string.public java.lang.String getRoleMapStr()
public void assignRole(java.lang.String roleId, Member mbr)
roleId
- the identifier of the WF role (e.g. "validators")mbr
- the member to be assigned to the rolepublic void assignRole(java.lang.String roleId, java.util.TreeSet<Member> mbrSet)
public void unassignRole(java.lang.String roleId)
roleId
- the identifier of the WF role (e.g. "validators")public void unassignMember(Member mbr)
mbr
- the member to be unassigned.public boolean isRoleAssigned(java.lang.String roleId)
roleId
- the WFRole ID to be checkedpublic java.util.TreeSet<Member> getMemberSetAssignedToRole(java.lang.String roleId)
roleId
- the WFRole ID to be checkedpublic boolean isInRole(java.lang.String roleId, Member mbr)
roleId
- the WFRole IDmbr
- the member to be checkedpublic java.util.TreeSet<java.lang.String> getFriendlyURLSet()
public void setFriendlyURLSet(java.util.TreeSet<java.lang.String> v)
v
- Value to assign to friendlyURLSet.public boolean hasBeenReadBy(Member mbr)
mbr
- The member you want to testpublic java.util.List<ReaderTracker> getReaderTrackerList()
public int getReaderCount()
public void setReaderCount(int v)
v
- the valuepublic int getAccessCount()
public void trackReader(Member mbr)
mbr
- the user to be tracked (may be null).public void trackReader(Member mbr, int accessType)
mbr
- the user to be tracked (may be null).accessType
- the type of accesspublic void removeAllReaderTracker(Member opAuthor)
opAuthor
- the member who performs this operationprotected void removeDataSet(Member opAuthor, java.util.Set<? extends Data> dataSet)
opAuthor
- the member who performs this operationdataSet
- the data set to be removedpublic void removeAllDescendants(Member opAuthor, java.util.Map context)
opAuthor
- the member who performs this operationcontext
- the DataController's contextpublic boolean hasAlreadyVoted(Member member)
member
- the member to checkpublic void addWFExpressAlarm()
public void removeWFExpressAlarm()
public void addWFReminderAlarm()
public void removeWFReminderAlarm()
public int getEstimatedReminderCount()
public java.lang.Object[] checkStateChange(Member mbr, int newPstatus)
mbr
- the member who submit the state changenewPstatus
- the new pstatuspublic java.lang.Object[] checkStateChange(Member mbr, int newPstatus, int oldPstatus)
mbr
- the member who submit the state changenewPstatus
- the new pstatusoldPstatus
- the old pstatuspublic boolean createWFNote(Member mbr, int newPstatus, java.lang.String note)
mbr
- the member which performe this operationnewPstatus
- new pstatusnote
- member's commentpublic boolean createWFNote(Member mbr, int newPstatus, int oldPstatus, java.lang.String note)
mbr
- the member which performe this operationnewPstatus
- new pstatusoldPstatus
- old pstatusnote
- member's commentpublic static <T extends Publication> java.util.Comparator<T> getTitleComparator()
Publication.TitleComparator
.public static <T extends Publication> java.util.Comparator<T> getTitleComparator(java.lang.String lang)
lang
- the user languagePublication.TitleComparator
using the given language.public static <T extends Publication> java.util.Comparator<T> getPdateComparator()
Publication.PdateComparator
.public static <T extends Publication> java.util.Comparator<T> getEdateComparator()
Publication.EdateComparator
.public static <T extends Publication> java.util.Comparator<T> getSdateComparator()
Publication.SdateComparator
.public static <T extends Publication> java.util.Comparator<T> getAdateComparator()
Publication.AdateComparator
.public static <T extends Publication> java.util.Comparator<T> getUdateComparator()
Publication.UdateComparator
.public static <T extends Publication> java.util.Comparator<T> getDdateComparator()
Publication.DdateComparator
.public static <T extends Publication> java.util.Comparator<T> getWorkspaceComparator(java.lang.String lang)
lang
- the user languagePublication.WorkspaceComparator
.public static <T extends Publication> java.util.Comparator<T> getPstatusComparator()
Publication.PstatusComparator
.public static <T extends Publication> java.util.Comparator<T> getRightComparator()
Publication.RightComparator
.public static <T extends Publication> java.util.Comparator<T> getAudienceRightComparator()
Publication.AudienceRightComparator
.public static <T extends Publication> java.util.Comparator<T> getTypeComparator()
Publication.TypeComparator
.public static <T extends Publication> java.util.Comparator<T> getReaderComparator()
Publication.ReaderComparator
.public static <T extends Publication> java.util.Comparator<T> getVoteScoreComparator()
Publication.VoteScoreComparator
.public static <T extends Publication> java.util.Comparator<T> getPopularityComparator()
Publication.PopularityComparator
.public static java.util.Comparator getComparator(java.lang.String str, boolean reverse)
ComparatorManager
Comparator
given a name representing
it. The returned comparator can be used to sort any Collection
containing Publication
s. getTitleComparator()
getWorkspaceComparator(String)
getPstatusComparator()
getRightComparator()
getAudienceRightComparator()
getTypeComparator()
getPdateComparator()
getEdateComparator()
getSdateComparator()
getAdateComparator()
getUdateComparator()
getDdateComparator()
getReaderComparator()
Data.getComparator(String, boolean)
str
- a string representing the comparatorreverse
- a boolean indicating whether the comparator should have
its behavior reversed (true) or unchanged (false)Comparator
.Data.getComparator(String, boolean)
public static <T extends Publication> java.util.Comparator<T> getComparator(java.lang.Class<T> clazz, java.lang.String str, boolean reverse)
ComparatorManager
public static java.util.Comparator getComparator(java.lang.String str, boolean reverse, QueryResultSet queryResultSet)
ComparatorManager
Comparator
given a name representing
it. The returned comparator can be used to sort any Collection
containing Publication
s. getComparator(String, boolean)
QueryResultSet.getScoreComparator(QueryResultSet, Comparator)
with the givenqueryResultSet and
BasicStorable.getMdateComparator()
Comparator
to use when returning
a SortedSet
.getComparator(String, boolean)
,
Data.getComparator(String, boolean)
public java.util.Date getDate(java.lang.String dateType)
public java.util.Date getDate(java.lang.String dateType, java.util.Date defaultDate)
public java.util.Date getIndexingDate()
public static Publication.AuthorizedSelector getAuthorizedSelector(Member member)
Publication.AuthorizedSelector
using
the given Member
.public static Publication.CanWorkOnSelector getCanWorkOnSelector(Member member)
Publication.CanWorkOnSelector
using
the given Member
.public static Publication.WorkspaceSelector getWorkspaceSelector(Workspace workspace)
Publication.WorkspaceAuthorSelector
using
the given Workspace
.public static Publication.WorkspaceAuthorSelector getWorkspaceAuthorSelector(Workspace workspace, Member author)
Publication.WorkspaceAuthorSelector
using
the given Workspace
and Member
.public static Publication.VisibleStateSelector getVisibleStateSelector()
Publication.VisibleStateSelector
.public static Publication.PstatusSelector getPstatusSelector(int pstatus)
Publication.PstatusSelector
.Publication.PstatusSelector
public static Publication.PstatusSelector getPstatusSelector(int pstatus, int greater)
Publication.PstatusSelector
.Publication.PstatusSelector
public static Publication.PdateSelector getPdateSelector(java.util.Date begin, java.util.Date end)
Publication.PdateSelector
using the given
begin and end Date
.public static Publication.SdateSelector getSdateSelector(java.util.Date begin, java.util.Date end)
Publication.SdateSelector
using the given
begin and end Date
.public static Publication.EdateSelector getEdateSelector(java.util.Date begin, java.util.Date end)
Publication.EdateSelector
using the given
begin and end Date
.public static Publication.AdateSelector getAdateSelector(java.util.Date begin, java.util.Date end)
Publication.AdateSelector
using the given
begin and end Date
.public static Publication.UdateSelector getUdateSelector(java.util.Date begin, java.util.Date end)
Publication.UdateSelector
using the given
begin and end Date
.public static DataSelector getDateSelector(java.lang.String str, java.util.Date begin, java.util.Date end)
DataSelector
given a name representing
it. The returned selector can be passed to the method JcmsUtil.applyDataSelector(java.util.Collection, DataSelector)
to
allow precise control over the selection of Data
in a Collection
. getPdateSelector(Date begin, Date end)
getSdateSelector(Date begin, Date end)
getEdateSelector(Date begin, Date end)
getAdateSelector(Date begin, Date end)
getUdateSelector(Date begin, Date end)
Data.getDateSelector(String, Date, Date)
str
- a string representing the selectorbegin
- the begin Date
to use for selectionend
- the end Date
to use for selectionComparator
.Data.getDateSelector(String, Date, Date)
public static Publication.TrackedSelector getTrackedSelector()
Publication.TrackedSelector
.public static Publication.AudienceRightSelector getAudienceRightSelector()
Publication.AudienceRightSelector
.public static Publication.ReadRightSelector getReadRightSelector()
Publication.ReadRightSelector
.public java.util.Collection<? extends TreeNode> getTreeChildren()
TreeNode
getTreeChildren
in interface TreeNode
TreeNode.getTreeChildren()
public TreeNode getTreeParent()
TreeNode
getTreeParent
in interface TreeNode
TreeNode.getTreeParent()
public boolean isTreeLeaf()
TreeNode
isTreeLeaf
in interface TreeNode
TreeNode.isTreeLeaf()
public boolean isTreeNode()
TreeNode
isTreeNode
in interface TreeNode
TreeNode.isTreeNode()
public TreeNode getTreeRoot()
TreeNode
getTreeRoot
in interface TreeNode
public ControllerStatus checkIntegrity()
checkIntegrity
in class Data
public ControllerStatus checkWrite(int op, Member mbr, boolean checkIntegrity, java.util.Map context)
checkWrite
in class Data
op
- the operation (OP_CREATE, OP_UPDATE, ...)mbr
- the member which requests the write operationcheckIntegrity
- if true, requires the constraints integrity to be checkedcontext
- a map which contains context parameters (may be null)public ControllerStatus checkMember(int op, Member mbr, java.util.Map context)
checkMember
in class Data
op
- the operation (OP_CREATE, OP_UPDATE, ...)mbr
- the member which requests the write operationcontext
- a map which contains context parameters (may be null)public ControllerStatus checkCreate(Member mbr, java.util.Map context)
checkCreate
in class Data
mbr
- the member which requests the write operationcontext
- a map which contains context parameters (may be null)public ControllerStatus checkUpdate(Member mbr, java.util.Map context)
checkUpdate
in class Data
mbr
- the member which requests the write operationcontext
- a map which contains context parameters (may be null)public ControllerStatus checkDelete(Member mbr, java.util.Map context)
checkDelete
in class Data
mbr
- the member which requests the write operationcontext
- a map which contains context parameters (may be null)public ControllerStatus checkMerge(Member mbr, java.util.Map context)
mbr
- the member which requests the write operationcontext
- a map which contains context parameters (may be null)public void performCreate(Member mbr, java.util.Map context)
performCreate
in class Data
mbr
- the member which requests the write operationcontext
- a map which contains context parameters (may be null)public void performUpdate(Member mbr, java.util.Map context)
performUpdate
in class Data
mbr
- the member which requests the write operationcontext
- a map which contains context parameters (may be null)public void performDelete(Member mbr, java.util.Map context)
performDelete
in class Data
mbr
- the member which requests the write operationcontext
- a map which contains context parameters (may be null)protected Publication prepareMergeCopy()
public void performMerge(Member mbr)
mbr
- the member which requests the write operationpublic void performMerge(Member mbr, java.util.Map context)
mbr
- the member which requests the write operationcontext
- a map which contains context parameters (may be null)public DBDataRevision getDBDataRevision(Data data, int op)
protected void performBeforeWrite(int op, Member mbr, java.util.Map context)
Data
performBeforeWrite
in class Data
op
- the operation (OP_CREATE, OP_UPDATE, ...)mbr
- the member which requests the write operationcontext
- a map which contains context parameters (may be null)protected void performAfterWrite(int op, Member mbr, java.util.Map context)
Data
performAfterWrite
in class Data
op
- the operation (OP_CREATE, OP_UPDATE, ...)mbr
- the member which requests the write operationcontext
- a map which contains context parameters (may be null)public java.lang.Object getFieldValue(java.lang.String fieldName, java.lang.String lang, boolean useDefault) throws java.lang.NoSuchFieldException
Object
field name for the current Data
. Category
fields, see #getCategoryFieldValue(String, Member).getFieldValue
in class Data
fieldName
- the field name from which to retrieve the field value.lang
- the language (ISO-639 code) in which to retrieve the field value
(used only for multilingual fields).useDefault
- whether to use the publication main language if the field value
is not available in the requested language (used only for multilingual fields).Object
field valuejava.lang.NoSuchFieldException
- if the field was not found in the given Data
.public void setFieldValue(java.lang.String fieldName, java.lang.Object value, java.lang.String lang) throws java.lang.NoSuchFieldException
Object
field name for the current Data
. Category
fields, see #getCategoryFieldValue(String, Member).setFieldValue
in class Data
fieldName
- the field name from which to retrieve the field value.value
- whether to use the publication main language if the field value
is not available in the requested language (used only for multilingual fields).lang
- the language (ISO-639 code) in which to retrieve the field value
(used only for multilingual fields).java.lang.NoSuchFieldException
- if the field was not found in the given Data
.public void assignCommonPublicationFields(Publication pub)
As of current implementation, the following fields are copied :
pub
- the publication to copy from.public java.lang.String getImportVersion()
public void setImportVersion(java.lang.String v)
v
- Value to assign to importVersion.public java.util.List<WFNote> getWFNoteList()
public java.lang.String getWorkspaceId()
public void setWorkspaceId(java.lang.String v)
v
- the JStore workspace idpublic void initializeDBDataCollections()
Data
initializeDBDataCollections
in class Data
public void cloneDBDataCollections()
Copyright © 2001-2010 Jalios SA. All Rights Reserved.