com.stratelia.silverpeas.chat
Class ChatContentManager

java.lang.Object
  extended by com.stratelia.silverpeas.chat.ChatContentManager
All Implemented Interfaces:
com.stratelia.silverpeas.contentManager.ContentInterface

public class ChatContentManager
extends Object
implements com.stratelia.silverpeas.contentManager.ContentInterface

The chat implementation of ContentInterface.


Constructor Summary
ChatContentManager()
           
 
Method Summary
 int createSilverContent(Connection con, ChatRoomDetail chatRoom)
          add a new content.
 void deleteSilverContent(Connection con, String chatRoomId, String componentId)
          delete a content.
 List getSilverContentById(List ids, String peasId, String userId, List userRoles)
          Find all the SilverContent with the given list of SilverContentId
 int getSilverObjectId(String chatRoomId, String peasId)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ChatContentManager

public ChatContentManager()
Method Detail

getSilverContentById

public List getSilverContentById(List ids,
                                 String peasId,
                                 String userId,
                                 List userRoles)
Find all the SilverContent with the given list of SilverContentId

Specified by:
getSilverContentById in interface com.stratelia.silverpeas.contentManager.ContentInterface
Parameters:
ids - list of silverContentId to retrieve
peasId - the id of the instance
userId - the id of the user who wants to retrieve silverContent
userRoles - the roles of the user
Returns:
a List of SilverContent

getSilverObjectId

public int getSilverObjectId(String chatRoomId,
                             String peasId)
                      throws ChatException
Throws:
ChatException

createSilverContent

public int createSilverContent(Connection con,
                               ChatRoomDetail chatRoom)
                        throws com.stratelia.silverpeas.contentManager.ContentManagerException
add a new content. It is registered to contentManager service

Parameters:
con - a Connection
chatRoom - the content to register
Returns:
the unique silverObjectId which identified the new content
Throws:
com.stratelia.silverpeas.contentManager.ContentManagerException

deleteSilverContent

public void deleteSilverContent(Connection con,
                                String chatRoomId,
                                String componentId)
                         throws com.stratelia.silverpeas.contentManager.ContentManagerException
delete a content. It is registered to contentManager service

Parameters:
con - a Connection
chatRoomId - the identifiant of the content to unregister
componentId - the identifiant of the component instance where the content to unregister is
Throws:
com.stratelia.silverpeas.contentManager.ContentManagerException


Copyright © 2016 Silverpeas. All Rights Reserved.