F
- the actual type of factory.public class DefaultWorkflowAwareContent<F extends DefaultWorkflowAwareContentFactory> extends DefaultContent<F> implements WorkflowAwareContent
Content
, also versionable, lockable and workflow-aware.ATTACHMENTS_NODE_NAME, DEFAULT_CONTENT_LOCALE, METADATA_CONTENTTYPE, METADATA_CONTRIBUTOR, METADATA_CREATION, METADATA_CREATOR, METADATA_LANGUAGE, METADATA_LAST_MAJORVALIDATION, METADATA_LAST_VALIDATION, METADATA_MIXINCONTENTTYPES, METADATA_MODIFIED, METADATA_OUTGOING_REFERENCE_PROPERTY, METADATA_OUTGOING_REFERENCES, METADATA_OUTGOING_REFERENCES_PATH_PROPERTY, METADATA_ROOT_OUTGOING_REFERENCES, METADATA_TITLE
PROTECTED_PROPERTIES
Constructor and Description |
---|
DefaultWorkflowAwareContent(Node node,
String parentPath,
F factory)
Creates a JCR-based Content.
|
Modifier and Type | Method and Description |
---|---|
long |
getCurrentStepId()
Retrieves the current step id of the Ametys object
|
Date |
getProposalDate()
Retrieves the date at which the content was proposed for validation,
i.e.
|
long |
getWorkflowId()
Retrieves the workflow id associated with the Ametys object.
|
void |
remove()
Removes this
AmetysObject from the Ametys tree. |
void |
setCurrentStepId(long stepId)
Set the current step id of the Ametys object
|
void |
setProposalDate(Date proposalDate)
Set the date at which the content was proposed for validation, i.e.
|
void |
setWorkflowId(long workflowId)
Set the workflow id of this Ametys object.
This method will throw Exception if the workflow id was already set on this Ametys object. |
_checkLock, copyTo, copyTo, copyTo, copyTo, copyTo, createChild, getChild, getChildren, getCreationDate, getCreator, getDCContributor, getDCCoverage, getDCCreator, getDCDate, getDCDescription, getDCFormat, getDCIdentifier, getDCLanguage, getDCPublisher, getDCRelation, getDCRights, getDCSource, getDCSubject, getDCTitle, getDCType, getLanguage, getLastContributor, getLastMajorValidationDate, getLastModified, getLastValidationDate, getMixinTypes, getOutgoingReferences, getReferencingContents, getRootAttachments, getTags, getTitle, getTitle, getTypes, hasChild, hasReferencingContents
addAllowedGroups, addAllowedProfilesForAnonymous, addAllowedProfilesForAnyConnectedUser, addAllowedUsers, addDeniedGroups, addDeniedProfilesForAnonymous, addDeniedProfilesForAnyConnectedUser, addDeniedUsers, addLabel, checkpoint, copyNode, getAllLabels, getAllowedGroups, getAllowedProfilesForAnonymous, getAllowedProfilesForAnyConnectedUser, getAllowedProfilesForGroups, getAllowedProfilesForUser, getAllowedProfilesForUsers, getAllowedUsers, getAllRevisions, getBaseNode, getBaseVersion, getDeniedGroups, getDeniedProfilesForAnonymous, getDeniedProfilesForAnyConnectedUser, getDeniedProfilesForGroups, getDeniedProfilesForUser, getDeniedProfilesForUsers, getDeniedUsers, getLabels, getLabels, getNode, getRevision, getRevisionTimestamp, getRevisionTimestamp, getUnversionedMetadataHolder, getVersionHistory, removeAllowedGroups, removeAllowedGroups, removeAllowedProfilesForAnonymous, removeAllowedProfilesForAnyConnectedUser, removeAllowedUsers, removeAllowedUsers, removeDeniedGroups, removeDeniedGroups, removeDeniedProfilesForAnonymous, removeDeniedProfilesForAnyConnectedUser, removeDeniedUsers, removeDeniedUsers, removeLabel, restoreFromLabel, restoreFromNode, restoreFromRevision, switchToLabel, switchToRevision
_getFactory, _invalidateName, _invalidateParentPath, getId, getMetadataHolder, getName, getParent, getParentPath, getPath, needsSave, rename, revertChanges, saveChanges
equals, hashCode, toString
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getCreationDate, getCreator, getLanguage, getLastContributor, getLastMajorValidationDate, getLastModified, getLastValidationDate, getMixinTypes, getOutgoingReferences, getReferencingContents, getRootAttachments, getTitle, getTitle, getTypes, hasReferencingContents
getDCContributor, getDCCoverage, getDCCreator, getDCDate, getDCDescription, getDCFormat, getDCIdentifier, getDCLanguage, getDCPublisher, getDCRelation, getDCRights, getDCSource, getDCSubject, getDCTitle, getDCType
getTags
addAllowedGroups, addAllowedProfilesForAnonymous, addAllowedProfilesForAnyConnectedUser, addAllowedUsers, addDeniedGroups, addDeniedProfilesForAnonymous, addDeniedProfilesForAnyConnectedUser, addDeniedUsers, removeAllowedGroups, removeAllowedGroups, removeAllowedProfilesForAnonymous, removeAllowedProfilesForAnyConnectedUser, removeAllowedUsers, removeAllowedUsers, removeDeniedGroups, removeDeniedGroups, removeDeniedProfilesForAnonymous, removeDeniedProfilesForAnyConnectedUser, removeDeniedUsers, removeDeniedUsers
getAllowedGroups, getAllowedProfilesForAnonymous, getAllowedProfilesForAnyConnectedUser, getAllowedProfilesForGroups, getAllowedProfilesForUser, getAllowedProfilesForUsers, getAllowedUsers, getDeniedGroups, getDeniedProfilesForAnonymous, getDeniedProfilesForAnyConnectedUser, getDeniedProfilesForGroups, getDeniedProfilesForUser, getDeniedProfilesForUsers, getDeniedUsers
getNode
needsSave, rename, revertChanges, saveChanges
equals, getId, getName, getParent, getParentPath, getPath, hashCode
getChildAt, getChildPosition
public DefaultWorkflowAwareContent(Node node, String parentPath, F factory)
node
- the JCR Node backing this Content.parentPath
- the parent path in the Ametys hierarchy.factory
- the corresponding ContentFactory
.public long getWorkflowId() throws AmetysRepositoryException
WorkflowAwareAmetysObject
getWorkflowId
in interface WorkflowAwareAmetysObject
AmetysRepositoryException
- if an error occurs.public void setWorkflowId(long workflowId) throws AmetysRepositoryException
WorkflowAwareAmetysObject
setWorkflowId
in interface WorkflowAwareAmetysObject
workflowId
- the workflow id of the object.AmetysRepositoryException
- if an error occurs.public long getCurrentStepId() throws AmetysRepositoryException
WorkflowAwareAmetysObject
getCurrentStepId
in interface WorkflowAwareAmetysObject
AmetysRepositoryException
- if an error occurs.public void setCurrentStepId(long stepId) throws AmetysRepositoryException
WorkflowAwareAmetysObject
setCurrentStepId
in interface WorkflowAwareAmetysObject
stepId
- the step id to setAmetysRepositoryException
- if an error occurs.public Date getProposalDate() throws AmetysRepositoryException
WorkflowAwareContent
getProposalDate
in interface WorkflowAwareContent
AmetysRepositoryException
- if an error occurs.public void setProposalDate(Date proposalDate) throws AmetysRepositoryException
WorkflowAwareContent
setProposalDate
in interface WorkflowAwareContent
proposalDate
- the date at which the content was proposed for validation, or null to remove it.AmetysRepositoryException
- if an error occurs.public void remove() throws AmetysRepositoryException, RepositoryIntegrityViolationException
RemovableAmetysObject
AmetysObject
from the Ametys tree.remove
in interface RemovableAmetysObject
remove
in class SimpleAmetysObject<F extends DefaultWorkflowAwareContentFactory>
AmetysRepositoryException
- if an error occurs.RepositoryIntegrityViolationException
- if this AmetysObject
is referenced by another objects.