public class AlertScheduler extends TimerTask implements Initializable, LogEnabled, Serviceable, Disposable, Contextualizable, Configurable, Component
| Modifier and Type | Field and Description |
|---|---|
protected Configuration |
_configuration
The component configuration.
|
protected Context |
_context
The avalon context.
|
protected Logger |
_logger
The logger.
|
protected ServiceManager |
_manager
The service manager.
|
protected Timer |
_timer
The timer.
|
static String |
ROLE
The Avalon role
|
| Constructor and Description |
|---|
AlertScheduler() |
| Modifier and Type | Method and Description |
|---|---|
protected String |
_getRequestURI(Request request)
Get the request URI.
|
void |
configure(Configuration configuration) |
void |
contextualize(Context context) |
void |
dispose() |
void |
enableLogging(Logger logger) |
void |
initialize() |
void |
run() |
void |
sendInstantAlerts(List<String> contentIds,
String message)
Run the scheduler to send instant alerts on contents
|
void |
service(ServiceManager manager) |
cancel, scheduledExecutionTimeprotected ServiceManager _manager
protected Configuration _configuration
public AlertScheduler()
public void service(ServiceManager manager) throws ServiceException
service in interface ServiceableServiceExceptionpublic void contextualize(Context context) throws ContextException
contextualize in interface ContextualizableContextExceptionpublic void configure(Configuration configuration) throws ConfigurationException
configure in interface ConfigurableConfigurationExceptionpublic void enableLogging(Logger logger)
enableLogging in interface LogEnabledpublic void initialize() throws Exception
initialize in interface InitializableExceptionpublic void sendInstantAlerts(List<String> contentIds, String message)
contentIds - The ids of concerned contentsmessage - the message to send to authorized usersprotected String _getRequestURI(Request request)
request - the request object.public void dispose()
dispose in interface Disposable