Jive API (3.0.13) Core Javadocs

com.jivesoftware.community.event
Class ThreadEvent

java.lang.Object
  extended by 
      extended by com.jivesoftware.community.event.ThreadEvent

public class ThreadEvent
extends

A class for ForumThread events. This class will be passed to EventListeners whenever a thread event is fired and contains all the pertinent information to the event.

Certain event types will populate the params Map with additional objects as outlined below:

Event Type Extra Params
ADDED None
DELETING threadID
messageIDs -- a List of messageIDs belonging to the thread
DELETED threadID
messageIDs -- a List of messageIDs belonging to the thread
MOVED oldCommunityID (Long) -- the ID of the community the thread used to belong to.
MODERATION_MODIFIEDoldModerationValue (Integer) -- the old moderation value of the thread.
moderatorID (Long) -- the userID of user that made the moderation change, or -1 if userID is unknown or not present.
VIEWED None


Nested Class Summary
static class ThreadEvent.Type
           
 
Field Summary
static String KEY_MESSAGE_IDS
           
static String KEY_MODERATOR_ID
           
static String KEY_OLD_CONTAINER_ID
           
static String KEY_OLD_CONTAINER_TYPE
           
static String KEY_OLD_MODERATION_VALUE
           
 
Constructor Summary
ThreadEvent()
           
ThreadEvent(ThreadEvent.Type eventType, ForumThread thread, JiveContainer container, Map<String,? extends Object> params)
          Creates a new thread event.
 
Method Summary
 ModificationType getContentModificationType()
          A modification type from the list below that corresponds to the implementing event's type.
 EntityDescriptor getJiveContainer()
           
 EntityDescriptor getOldContainer()
           
 long getOldModerationValue()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

KEY_OLD_MODERATION_VALUE

public static final String KEY_OLD_MODERATION_VALUE
See Also:
Constant Field Values

KEY_OLD_CONTAINER_TYPE

public static final String KEY_OLD_CONTAINER_TYPE
See Also:
Constant Field Values

KEY_OLD_CONTAINER_ID

public static final String KEY_OLD_CONTAINER_ID
See Also:
Constant Field Values

KEY_MODERATOR_ID

public static final String KEY_MODERATOR_ID
See Also:
Constant Field Values

KEY_MESSAGE_IDS

public static final String KEY_MESSAGE_IDS
See Also:
Constant Field Values
Constructor Detail

ThreadEvent

public ThreadEvent()

ThreadEvent

public ThreadEvent(ThreadEvent.Type eventType,
                   ForumThread thread,
                   JiveContainer container,
                   Map<String,? extends Object> params)
Creates a new thread event.

Parameters:
eventType - the type of the message event.
thread - the message the event corresponds to.
container - the parent container
params - parameters corresponding to the event.
Method Detail

getJiveContainer

public EntityDescriptor getJiveContainer()

getOldModerationValue

public long getOldModerationValue()

getOldContainer

public EntityDescriptor getOldContainer()

getContentModificationType

public ModificationType getContentModificationType()
A modification type from the list below that corresponds to the implementing event's type.

Returns:
a ModificationType.

Jive Product Page

Copyright © 1999-2007 Jive Software.