Package org.ametys.web.workflow.archive
Class ArchiveContentsSchedulable
java.lang.Object
org.ametys.runtime.plugin.component.AbstractLogEnabled
org.ametys.plugins.core.impl.schedule.AbstractStaticSchedulable
org.ametys.cms.workflow.archive.ArchiveContentsSchedulable
org.ametys.web.workflow.archive.ArchiveContentsSchedulable
- All Implemented Interfaces:
Schedulable,LogEnabled,PluginAware,Component,Configurable,Contextualizable,Serviceable
Runnable engine that archive the contents that have an scheduled archiving
date set before the current date.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.ametys.plugins.core.impl.schedule.AbstractStaticSchedulable
AbstractStaticSchedulable.SchedulableParameterParser -
Field Summary
Fields inherited from class org.ametys.cms.workflow.archive.ArchiveContentsSchedulable
_ametysResolver, _archiveRights, _baseUrl, _contentHelper, _environmentContext, _i18nUtils, _logger, _mailFrom, _manager, _rightManager, _sourceResolver, _sysadminMail, _userErrorMailBody, _userErrorMailSubject, _userMailBody, _userMailSubjectFields inherited from class org.ametys.plugins.core.impl.schedule.AbstractStaticSchedulable
_acceptConcurrentExecution, _context, _description, _iconGlyph, _iconLarge, _iconMedium, _iconSmall, _id, _label, _parameters, _pluginName, _private, _schedulableParameterTypeExtensionPoint, _smanager, _startTime, _userLanguagesManager, _userManager, PROGRESSION_TRACKER -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected String_getContentTitle(Content content, Locale locale) Get content title for mailprotected String_getRequestURI(Content content) Get the request URI to set in mailprotected StringgetArchiveActionUri(String contentId) Get the pipeline uri for the archive actiongetBodyParamsForContributors(Content content, boolean archived, Locale locale) Get email body parametersprotected voidsetRequestAttributes(Request request, Content content) Set the necessary request attributesMethods inherited from class org.ametys.cms.workflow.archive.ArchiveContentsSchedulable
_getAuthorizedContributorsByLanguage, _getContentsListAsString, _sendMailsToUsers, configure, contextualize, execute, getAdminEmailParams, getContentUri, sendErrorMailToContributors, sendMailToAdministrator, sendMailToContributors, serviceMethods inherited from class org.ametys.plugins.core.impl.schedule.AbstractStaticSchedulable
acceptConcurrentExecution, getDescription, getIconGlyph, getIconLarge, getIconMedium, getIconSmall, getId, getLabel, getParameters, getProgressionTracker, isPrivate, setPluginInfoMethods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger
-
Constructor Details
-
ArchiveContentsSchedulable
public ArchiveContentsSchedulable()
-
-
Method Details
-
getArchiveActionUri
Description copied from class:ArchiveContentsSchedulableGet the pipeline uri for the archive action- Overrides:
getArchiveActionUriin classArchiveContentsSchedulable- Parameters:
contentId- the current contend id- Returns:
- a pipeline uri
-
setRequestAttributes
Description copied from class:ArchiveContentsSchedulableSet the necessary request attributes- Overrides:
setRequestAttributesin classArchiveContentsSchedulable- Parameters:
request- The requestcontent- The content
-
getBodyParamsForContributors
protected List<String> getBodyParamsForContributors(Content content, boolean archived, Locale locale) Description copied from class:ArchiveContentsSchedulableGet email body parameters- Overrides:
getBodyParamsForContributorsin classArchiveContentsSchedulable- Parameters:
content- the archived contentarchived- true if the content has archivedlocale- The locale of the mail. Cannot be null.- Returns:
- The mail parameters
-
_getRequestURI
Description copied from class:ArchiveContentsSchedulableGet the request URI to set in mail- Overrides:
_getRequestURIin classArchiveContentsSchedulable- Parameters:
content- The content. Can be null- Returns:
- the request URI
-
_getContentTitle
Description copied from class:ArchiveContentsSchedulableGet content title for mail- Overrides:
_getContentTitlein classArchiveContentsSchedulable- Parameters:
content- the contentlocale- The locale in which to get the content title- Returns:
- the content title
-