public class ScheduleArchivingClientSideElement extends StaticClientSideElement
ClientSideElement.Script, ClientSideElement.ScriptFile
Modifier and Type | Field and Description |
---|---|
private static String |
__I18N_KEY_CONTENT_TYPE_ERROR
I18n error key : content type error
|
private static String |
__I18N_KEY_UNEXPECTED_ERROR
I18n error key : unexpected error
|
private ObservationManager |
_observationManager |
private AmetysObjectResolver |
_resolver |
_currentUserProvider, _dependencies, _featureName, _id, _pluginName, _rightManager, _rights, _rightsMode, _script
Constructor and Description |
---|
ScheduleArchivingClientSideElement() |
Modifier and Type | Method and Description |
---|---|
private Date |
getDateNearestToCurrent(Set<Date> dates) |
Map<String,Object> |
getScheduledArchivingDate(List<String> contentIds)
Gets the scheduled archiving dates of one or several contents
|
List<ClientSideElement.Script> |
getScripts(boolean ignoreRights,
Map<String,Object> contextParameters)
This method return the scripts that will be used on client side.
|
void |
service(ServiceManager manager) |
Map<String,Object> |
setScheduledArchivingDate(List<String> contentIds,
String scheduledDateAsStr)
Set or remove the
ArchiveConstants.META_ARCHIVE_SCHEDULED_DATE on a content. |
_configureClass, _configureParameters, _configureScript, configureInitialParameters
_configureDependencies, _configureImports, _configureRights, _configureRightsMode, configure, getDependencies, getId, getPluginName, getRights, getScripts, hasRight, setPluginInfo, toString
getLogger, setLogger
private static final String __I18N_KEY_CONTENT_TYPE_ERROR
private static final String __I18N_KEY_UNEXPECTED_ERROR
private ObservationManager _observationManager
private AmetysObjectResolver _resolver
public ScheduleArchivingClientSideElement()
public void service(ServiceManager manager) throws ServiceException
service
in interface Serviceable
service
in class StaticFileImportsClientSideElement
ServiceException
public Map<String,Object> setScheduledArchivingDate(List<String> contentIds, String scheduledDateAsStr)
ArchiveConstants.META_ARCHIVE_SCHEDULED_DATE
on a content.contentIds
- The ids of contentsscheduledDateAsStr
- The schedule date as stringpublic Map<String,Object> getScheduledArchivingDate(List<String> contentIds)
contentIds
- the ids of the contentsprivate Date getDateNearestToCurrent(Set<Date> dates)
public List<ClientSideElement.Script> getScripts(boolean ignoreRights, Map<String,Object> contextParameters)
ClientSideElement
getScripts
in interface ClientSideElement
getScripts
in class StaticFileImportsClientSideElement
ignoreRights
- True to ignore the rights verification.contextParameters
- Contextuals parameters transmitted by the environment.