public class CreateContentFunction extends CreateContentFunction
Modifier and Type | Field and Description |
---|---|
protected CurrentUserProvider |
_currentUserProvider
Current user provider
|
protected SiteManager |
_siteManager
The sites manager
|
static String |
PAGE_KEY
Constant for knowing on which page the content will be affected.
|
static String |
PAGE_ZONE_KEY
Constant for knowing on which zone of the page to affect the content.
|
static String |
SITE_KEY
Constant for storing the site to use into the transient variables map.
|
_contentTypeEP, _contentTypeHelper, _observationManager, _resolver, CONTENT_LANGUAGE_KEY, CONTENT_MIXINS_KEY, CONTENT_NAME_KEY, CONTENT_TITLE_KEY, CONTENT_TITLE_VARIANTS_KEY, CONTENT_TYPES_KEY, PARENT_CONTENT_ID_KEY, PARENT_CONTENT_METADATA_PATH_KEY
_contentHelper, CONTENT_KEY
_logger, _manager, CONTEXT_PARAMETERS_KEY, FAIL_CONDITIONS_KEY, RESULT_MAP_KEY, WORKFLOW_ERRORS_KEY, WORKFLOW_WARNS_KEY
Constructor and Description |
---|
CreateContentFunction() |
Modifier and Type | Method and Description |
---|---|
protected ModifiableWorkflowAwareContent |
_createContent(Map transientVars,
String desiredContentName,
ModifiableTraversableAmetysObject contentsNode)
Create the content object.
|
protected AmetysObjectCollection<?,ModifiableWorkflowAwareContent> |
_getContentRoot(Map transientVars)
Retrieve the content root.
|
protected List<Future> |
_notifyContentAdded(Content content,
Map transientVars)
Notify observers that the content has been created
|
protected void |
_populateAdditionalData(Map transientVars,
ModifiableContent content)
Populate the content.
|
protected void |
_populateContent(Map transientVars,
ModifiableContent content)
Populate the content.
|
void |
service(ServiceManager manager) |
_getNonNullVar, _getObjectType, _getSubContentRoot, _isMultilingual, _setTitle, execute, getSystemUser
getContent
addWorkflowError, addWorkflowWarning, enableLogging, getConditionFailures, getContextParameters, getResultsMap, getUser
public static final String SITE_KEY
public static final String PAGE_KEY
public static final String PAGE_ZONE_KEY
protected SiteManager _siteManager
protected CurrentUserProvider _currentUserProvider
public CreateContentFunction()
public void service(ServiceManager manager) throws ServiceException
service
in interface Serviceable
service
in class CreateContentFunction
ServiceException
protected List<Future> _notifyContentAdded(Content content, Map transientVars) throws com.opensymphony.workflow.WorkflowException
CreateContentFunction
_notifyContentAdded
in class CreateContentFunction
content
- The content addedtransientVars
- The workflow varsFuture
objects of the asynchronous observerscom.opensymphony.workflow.WorkflowException
- If an error occurredprotected ModifiableWorkflowAwareContent _createContent(Map transientVars, String desiredContentName, ModifiableTraversableAmetysObject contentsNode)
CreateContentFunction
_createContent
in class CreateContentFunction
transientVars
- the workflow parameters.desiredContentName
- the desired content name.contentsNode
- the content root node in the repository.protected AmetysObjectCollection<?,ModifiableWorkflowAwareContent> _getContentRoot(Map transientVars) throws com.opensymphony.workflow.WorkflowException
CreateContentFunction
_getContentRoot
in class CreateContentFunction
transientVars
- the workflow parameters.com.opensymphony.workflow.WorkflowException
- if an error occursprotected void _populateContent(Map transientVars, ModifiableContent content) throws com.opensymphony.workflow.WorkflowException
CreateContentFunction
_populateContent
in class CreateContentFunction
transientVars
- the transient variables.content
- the content.com.opensymphony.workflow.WorkflowException
- if an error occurs.protected void _populateAdditionalData(Map transientVars, ModifiableContent content) throws com.opensymphony.workflow.WorkflowException
CreateContentFunction
_populateAdditionalData
in class CreateContentFunction
transientVars
- the transient variables.content
- the content.com.opensymphony.workflow.WorkflowException
- if an error occurs.