Class NewsPublishedEventType
- java.lang.Object
-
- org.ametys.runtime.plugin.component.AbstractLogEnabled
-
- org.ametys.plugins.repository.events.DefaultEventType
-
- org.ametys.plugins.workspaces.events.WorkspacesEventType
-
- org.ametys.plugins.workspaces.events.projects.ProjectsEventType
-
- org.ametys.plugins.workspaces.events.projects.ContentEventType
-
- org.ametys.plugins.workspaces.events.projects.NewsPublishedEventType
-
- All Implemented Interfaces:
EventType
,LogEnabled
,PluginAware
,Configurable
,Serviceable
public class NewsPublishedEventType extends ContentEventType
EventType
implementation for news publication
-
-
Field Summary
Fields Modifier and Type Field Description static String
EVENT_CONTENT_TAGS_PROPERTY
Constant for content's type-
Fields inherited from class org.ametys.plugins.workspaces.events.projects.ContentEventType
EVENT_CONTENT_ID_PROPERTY, EVENT_CONTENT_SUMMARY_PROPERTY, EVENT_CONTENT_TITLE_PROPERTY, EVENT_CONTENT_TYPE_PROPERTY, EVENT_PAGE_ID_PROPERTY
-
Fields inherited from class org.ametys.plugins.workspaces.events.projects.ProjectsEventType
EVENT_CATEGORY_PROJECTS
-
Fields inherited from class org.ametys.plugins.workspaces.events.WorkspacesEventType
_projectManager, _resolver, EVENT_PROJECT_CATEGORY_PROPERTY, EVENT_PROJECT_NAME_PROPERTY, EVENT_PROJECT_TITLE_PROPERTY, PROJECT_ACCESS, PROJECT_CATEGORY, PROJECT_NAME, PROJECT_TITLE, PROJECT_URL
-
Fields inherited from class org.ametys.plugins.repository.events.DefaultEventType
_currentUserProvider, _userHelper, AUTHOR, DATE, NAME, TYPE
-
Fields inherited from interface org.ametys.plugins.repository.events.EventType
EVENT_AUTHOR, EVENT_DATE, EVENT_TYPE
-
-
Constructor Summary
Constructors Constructor Description NewsPublishedEventType()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Map<String,Object>
event2JSON(Node eventNode)
Format an event node to JSONvoid
service(ServiceManager serviceManager)
protected void
storeAdditionalEventData(Node eventNode, Map<String,Object> parameters)
Store additional data on eventNode
storeEvent(String eventId, Map<String,Object> parameters, EventHolder eventHolder)
Store an event with the given event id under the given event holder node-
Methods inherited from class org.ametys.plugins.workspaces.events.projects.ContentEventType
_addNonNullProperty, isMergeable
-
Methods inherited from class org.ametys.plugins.repository.events.DefaultEventType
_getAuthor, configure, getSupportedTypes, mergeEvents, setPluginInfo
-
Methods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger
-
-
-
-
Field Detail
-
EVENT_CONTENT_TAGS_PROPERTY
public static final String EVENT_CONTENT_TAGS_PROPERTY
Constant for content's type- See Also:
- Constant Field Values
-
-
Constructor Detail
-
NewsPublishedEventType
public NewsPublishedEventType()
-
-
Method Detail
-
service
public void service(ServiceManager serviceManager) throws ServiceException
- Specified by:
service
in interfaceServiceable
- Overrides:
service
in classContentEventType
- Throws:
ServiceException
-
storeEvent
public Node storeEvent(String eventId, Map<String,Object> parameters, EventHolder eventHolder) throws RepositoryException
Description copied from interface:EventType
Store an event with the given event id under the given event holder node- Specified by:
storeEvent
in interfaceEventType
- Overrides:
storeEvent
in classDefaultEventType
- Parameters:
eventId
- the id of the event to storeparameters
- the event parameterseventHolder
- the event holder- Returns:
- the stored node
- Throws:
RepositoryException
- if an error occurs while manipulating the repository
-
storeAdditionalEventData
protected void storeAdditionalEventData(Node eventNode, Map<String,Object> parameters) throws RepositoryException
Description copied from class:DefaultEventType
Store additional data on event- Overrides:
storeAdditionalEventData
in classContentEventType
- Parameters:
eventNode
- The event nodeparameters
- The event's parameters- Throws:
RepositoryException
- if an error occurred
-
event2JSON
public Map<String,Object> event2JSON(Node eventNode) throws RepositoryException
Description copied from interface:EventType
Format an event node to JSON- Specified by:
event2JSON
in interfaceEventType
- Overrides:
event2JSON
in classContentEventType
- Parameters:
eventNode
- the node of an event- Returns:
- the JSON for the node
- Throws:
RepositoryException
- if an error occurs while manipulating the repository
-
-