Java Doc for MultiUserChatServerImpl.java in  » Net » openfire » org » jivesoftware » openfire » muc » spi » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Net » openfire » org.jivesoftware.openfire.muc.spi 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.jivesoftware.openfire.container.BasicModule
      org.jivesoftware.openfire.muc.spi.MultiUserChatServerImpl

MultiUserChatServerImpl
public class MultiUserChatServerImpl extends BasicModule implements MultiUserChatServer,ServerItemsProvider,DiscoInfoProvider,DiscoItemsProvider,RoutableChannelHandler,ClusterEventListener(Code)
Implements the chat server as a cached memory resident chat server. The server is also responsible for responding Multi-User Chat disco requests as well as removing inactive users from the rooms after a period of time and to maintain a log of the conversation in the rooms that require to log their conversations. The conversations log is saved to the database using a separate process

Temporary rooms are held in memory as long as they have occupants. They will be destroyed after the last occupant left the room. On the other hand, persistent rooms are always present in memory even after the last occupant left the room. In order to keep memory clean of persistent rooms that have been forgotten or abandoned this class includes a clean up process. The clean up process will remove from memory rooms that haven't had occupants for a while. Moreover, forgotten or abandoned rooms won't be loaded into memory when the Multi-User Chat service starts up.
author:
   Gaston Dombiak



Field Summary
 Collection<MUCEventListener>listeners
    
public  longtotalChatTime
    

Constructor Summary
public  MultiUserChatServerImpl()
     Create a new group chat server.

Method Summary
public  voidaddListener(MUCEventListener listener)
    
public  voidaddSysadmin(String userJID)
    
public  voidaddUserAllowedToCreate(String userJID)
    
public  voidchatRoomAdded(LocalMUCRoom room)
     Notification message indicating that a chat room has been created in another cluster member.
public  voidchatRoomRemoved(String roomName)
     Notification message indicating that the specified chat room was removed from some other cluster member.
public  voidenableService(boolean enabled, boolean persistent)
    
 voidfireMessageReceived(JID roomJID, JID user, String nickname, Message message)
    
 voidfireNicknameChanged(JID roomJID, JID user, String oldNickname, String newNickname)
    
 voidfireOccupantJoined(JID roomJID, JID user, String nickname)
    
 voidfireOccupantLeft(JID roomJID, JID user)
    
 voidfireRoomDestroyed(JID roomJID)
    
public  JIDgetAddress()
    
public  MUCRoomgetChatRoom(String roomName, JID userjid)
    
public  MUCRoomgetChatRoom(String roomName)
    
public  List<MUCRoom>getChatRooms()
    
public  StringgetDescription()
    
public  XDataFormImplgetExtendedInfo(String name, String node, JID senderJID)
    
public  Iterator<String>getFeatures(String name, String node, JID senderJID)
    
public  HistoryStrategygetHistoryStrategy()
    
public  Iterator<Element>getIdentities(String name, String node, JID senderJID)
    
public  Iterator<DiscoServerItem>getItems()
    
public  Iterator<DiscoItem>getItems(String name, String node, JID senderJID)
    
public  intgetKickIdleUsersTimeout()
    
public  intgetLogConversationBatchSize()
    
public  intgetLogConversationsTimeout()
    
public  Collection<MUCRole>getMUCRoles(JID user)
    
public  intgetNumberChatRooms()
     Retuns the number of existing rooms in the server (i.e.
public  intgetNumberConnectedUsers(boolean onlyLocal)
     Retuns the total number of occupants in all rooms in the server.
Parameters:
  onlyLocal - true if only users connected to this JVM will be considered.
public  intgetNumberRoomOccupants()
     Retuns the total number of users that have joined in all rooms in the server.
public  StringgetServiceDomain()
    
public  StringgetServiceName()
    
public  Collection<String>getSysadmins()
    
public  longgetTotalChatTime()
    
public  intgetUserIdleTime()
    
public  Collection<String>getUsersAllowedToCreate()
    
public  booleanhasChatRoom(String roomName)
    
public  booleanhasInfo(String name, String node, JID senderJID)
    
public  voidinitialize(JID jid, ComponentManager componentManager)
    
public  voidinitialize(XMPPServer server)
    
public  booleanisAllowToDiscoverLockedRooms()
     Returns the flag that indicates if the service should provide information about locked rooms when handling service discovery requests.
public  booleanisRoomCreationRestricted()
    
public  booleanisServiceEnabled()
    
public  voidjoinedCluster()
    
public  voidjoinedCluster(byte[] nodeID)
    
public  voidleftCluster()
    
public  voidleftCluster(byte[] nodeID)
    
public  voidlogConversation(MUCRoom room, Message message, JID sender)
    
public  voidmarkedAsSeniorClusterMember()
    
public  voidmessageBroadcastedTo(int numOccupants)
    
public  voidprocess(Packet packet)
    
public  voidprocessPacket(Packet packet)
    
public  voidremoveChatRoom(String roomName)
    
public  voidremoveListener(MUCEventListener listener)
    
public  voidremoveSysadmin(String userJID)
    
public  voidremoveUserAllowedToCreate(String userJID)
    
public  voidsetAllowToDiscoverLockedRooms(boolean allowToDiscoverLockedRooms)
     Sets the flag that indicates if the service should provide information about locked rooms when handling service discovery requests. Note: Setting this flag in false is not compliant with the spec.
public  voidsetKickIdleUsersTimeout(int timeout)
    
public  voidsetLogConversationBatchSize(int size)
    
public  voidsetLogConversationsTimeout(int timeout)
    
public  voidsetRoomCreationRestricted(boolean roomCreationRestricted)
    
public  voidsetServiceName(String name)
    
public  voidsetUserIdleTime(int idleTime)
    
public  voidshutdown()
    
public  voidstart()
    
public  voidstop()
    

Field Detail
listeners
Collection<MUCEventListener> listeners(Code)



totalChatTime
public long totalChatTime(Code)
The total time all agents took to chat *




Constructor Detail
MultiUserChatServerImpl
public MultiUserChatServerImpl()(Code)
Create a new group chat server.




Method Detail
addListener
public void addListener(MUCEventListener listener)(Code)



addSysadmin
public void addSysadmin(String userJID)(Code)



addUserAllowedToCreate
public void addUserAllowedToCreate(String userJID)(Code)



chatRoomAdded
public void chatRoomAdded(LocalMUCRoom room)(Code)
Notification message indicating that a chat room has been created in another cluster member.
Parameters:
  room - the created room in another cluster node.



chatRoomRemoved
public void chatRoomRemoved(String roomName)(Code)
Notification message indicating that the specified chat room was removed from some other cluster member.
Parameters:
  roomName - the name of the room removed from the cluster.



enableService
public void enableService(boolean enabled, boolean persistent)(Code)



fireMessageReceived
void fireMessageReceived(JID roomJID, JID user, String nickname, Message message)(Code)



fireNicknameChanged
void fireNicknameChanged(JID roomJID, JID user, String oldNickname, String newNickname)(Code)



fireOccupantJoined
void fireOccupantJoined(JID roomJID, JID user, String nickname)(Code)



fireOccupantLeft
void fireOccupantLeft(JID roomJID, JID user)(Code)



fireRoomDestroyed
void fireRoomDestroyed(JID roomJID)(Code)



getAddress
public JID getAddress()(Code)



getChatRoom
public MUCRoom getChatRoom(String roomName, JID userjid) throws NotAllowedException(Code)



getChatRoom
public MUCRoom getChatRoom(String roomName)(Code)



getChatRooms
public List<MUCRoom> getChatRooms()(Code)



getDescription
public String getDescription()(Code)



getExtendedInfo
public XDataFormImpl getExtendedInfo(String name, String node, JID senderJID)(Code)



getFeatures
public Iterator<String> getFeatures(String name, String node, JID senderJID)(Code)



getHistoryStrategy
public HistoryStrategy getHistoryStrategy()(Code)



getIdentities
public Iterator<Element> getIdentities(String name, String node, JID senderJID)(Code)



getItems
public Iterator<DiscoServerItem> getItems()(Code)



getItems
public Iterator<DiscoItem> getItems(String name, String node, JID senderJID)(Code)



getKickIdleUsersTimeout
public int getKickIdleUsersTimeout()(Code)



getLogConversationBatchSize
public int getLogConversationBatchSize()(Code)



getLogConversationsTimeout
public int getLogConversationsTimeout()(Code)



getMUCRoles
public Collection<MUCRole> getMUCRoles(JID user)(Code)



getNumberChatRooms
public int getNumberChatRooms()(Code)
Retuns the number of existing rooms in the server (i.e. persistent or not, in memory or not). the number of existing rooms in the server.



getNumberConnectedUsers
public int getNumberConnectedUsers(boolean onlyLocal)(Code)
Retuns the total number of occupants in all rooms in the server.
Parameters:
  onlyLocal - true if only users connected to this JVM will be considered. Otherwise count cluster wise. the number of existing rooms in the server.



getNumberRoomOccupants
public int getNumberRoomOccupants()(Code)
Retuns the total number of users that have joined in all rooms in the server. the number of existing rooms in the server.



getServiceDomain
public String getServiceDomain()(Code)



getServiceName
public String getServiceName()(Code)



getSysadmins
public Collection<String> getSysadmins()(Code)



getTotalChatTime
public long getTotalChatTime()(Code)



getUserIdleTime
public int getUserIdleTime()(Code)



getUsersAllowedToCreate
public Collection<String> getUsersAllowedToCreate()(Code)



hasChatRoom
public boolean hasChatRoom(String roomName)(Code)



hasInfo
public boolean hasInfo(String name, String node, JID senderJID)(Code)



initialize
public void initialize(JID jid, ComponentManager componentManager)(Code)



initialize
public void initialize(XMPPServer server)(Code)



isAllowToDiscoverLockedRooms
public boolean isAllowToDiscoverLockedRooms()(Code)
Returns the flag that indicates if the service should provide information about locked rooms when handling service discovery requests. true if the service should provide information about locked rooms.



isRoomCreationRestricted
public boolean isRoomCreationRestricted()(Code)



isServiceEnabled
public boolean isServiceEnabled()(Code)



joinedCluster
public void joinedCluster()(Code)



joinedCluster
public void joinedCluster(byte[] nodeID)(Code)



leftCluster
public void leftCluster()(Code)



leftCluster
public void leftCluster(byte[] nodeID)(Code)



logConversation
public void logConversation(MUCRoom room, Message message, JID sender)(Code)



markedAsSeniorClusterMember
public void markedAsSeniorClusterMember()(Code)



messageBroadcastedTo
public void messageBroadcastedTo(int numOccupants)(Code)



process
public void process(Packet packet) throws UnauthorizedException, PacketException(Code)



processPacket
public void processPacket(Packet packet)(Code)



removeChatRoom
public void removeChatRoom(String roomName)(Code)



removeListener
public void removeListener(MUCEventListener listener)(Code)



removeSysadmin
public void removeSysadmin(String userJID)(Code)



removeUserAllowedToCreate
public void removeUserAllowedToCreate(String userJID)(Code)



setAllowToDiscoverLockedRooms
public void setAllowToDiscoverLockedRooms(boolean allowToDiscoverLockedRooms)(Code)
Sets the flag that indicates if the service should provide information about locked rooms when handling service discovery requests. Note: Setting this flag in false is not compliant with the spec. A user may try to join a locked room thinking that the room doesn't exist because the user didn't discover it before.
Parameters:
  allowToDiscoverLockedRooms - if the service should provide information about lockedrooms.



setKickIdleUsersTimeout
public void setKickIdleUsersTimeout(int timeout)(Code)



setLogConversationBatchSize
public void setLogConversationBatchSize(int size)(Code)



setLogConversationsTimeout
public void setLogConversationsTimeout(int timeout)(Code)



setRoomCreationRestricted
public void setRoomCreationRestricted(boolean roomCreationRestricted)(Code)



setServiceName
public void setServiceName(String name)(Code)



setUserIdleTime
public void setUserIdleTime(int idleTime)(Code)



shutdown
public void shutdown()(Code)



start
public void start()(Code)



stop
public void stop()(Code)



Methods inherited from org.jivesoftware.openfire.container.BasicModule
public void destroy()(Code)(Java Doc)
public String getName()(Code)(Java Doc)
public void initialize(XMPPServer server)(Code)(Java Doc)
public void start() throws IllegalStateException(Code)(Java Doc)
public void stop()(Code)(Java Doc)

Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.