Class PollActivityPublicationListener
java.lang.Object
org.exoplatform.container.component.BaseComponentPlugin
org.exoplatform.social.common.lifecycle.AbstractListenerPlugin
org.exoplatform.social.core.activity.ActivityListenerPlugin
io.meeds.poll.listener.PollActivityPublicationListener
- All Implemented Interfaces:
org.exoplatform.container.component.ComponentPlugin, org.exoplatform.social.common.lifecycle.LifeCycleListener<org.exoplatform.social.core.activity.ActivityLifeCycleEvent>, org.exoplatform.social.core.activity.ActivityListener
@Component
public class PollActivityPublicationListener
extends org.exoplatform.social.core.activity.ActivityListenerPlugin
Computes the dates of a scheduled poll when its activity is published,
for the activity of that poll only.
-
Field Summary
Fields inherited from class org.exoplatform.container.component.BaseComponentPlugin
desc, name -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidinit()Registers this listener on the activity events.voidsaveActivity(org.exoplatform.social.core.activity.ActivityLifeCycleEvent event) Computes the dates of the poll of a scheduled poll activity from its effective publication, when the activity is the one of that poll.Methods inherited from class org.exoplatform.container.component.BaseComponentPlugin
getDescription, getName, setDescription, setNameMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.exoplatform.social.core.activity.ActivityListener
deleteActivity, deleteComment, deleteLikeActivity, deleteLikeComment, hideActivity, likeActivity, likeComment, pinActivity, saveComment, shareActivity, unpinActivity, updateActivity, updateCategories, updateCommentMethods inherited from interface org.exoplatform.social.common.lifecycle.LifeCycleListener
getDescription, getName, setDescription, setName
-
Constructor Details
-
PollActivityPublicationListener
public PollActivityPublicationListener()
-
-
Method Details
-
init
@PostConstruct public void init()Registers this listener on the activity events. -
saveActivity
public void saveActivity(org.exoplatform.social.core.activity.ActivityLifeCycleEvent event) Computes the dates of the poll of a scheduled poll activity from its effective publication, when the activity is the one of that poll. Any other poll activity is ignored.- Parameters:
event- the activity creation event
-