|
Jive Forums API (5.5.20.2-oracle) Developer Javadocs | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.jivesoftware.webchat.user.UserSession
public final class UserSession
Manages all Group and 1-to-1 Chat Sessions.
Constructor Summary | |
---|---|
UserSession()
Creates a new session manager. |
Method Summary | |
---|---|
void |
addChatSession(java.lang.String participant,
ChatSession chatSession)
Adds a new ChatSession associated with a 1-to-1 converstation. |
void |
addGroupChatSession(java.lang.String roomName,
GroupChatSession chatSession)
Adds a new GroupChatSession identified by the room name. |
boolean |
checkForInvalidSession()
|
void |
closeAndRemoveGroupChatSession(java.lang.String roomName)
Closed and remove the GroupChatSession |
void |
closeConnection()
|
void |
destroyAllSessions()
Removes all Chat Sessions from map. |
java.util.Map |
getAllSessions()
Returns all active rooms. |
java.util.List |
getAvailableRooms()
|
ChatSession |
getChatSession(java.lang.String participant)
Retrieves the ChatSession associated with a 1-to-1 chat. |
GroupChatSession |
getGroupChatSession(java.lang.String roomName)
Retrieve's the GroupChatSession associated with the room. |
java.lang.String |
getNickname()
|
java.lang.String |
getPassword()
|
java.util.Map |
getPrivateMessageMap()
|
RoomInfo |
getRoomInfo(java.lang.String roomJID)
|
java.lang.String |
getUsername()
|
org.jivesoftware.smack.XMPPConnection |
getXMPPConnection()
|
boolean |
isActive()
|
boolean |
isAnonymous()
|
void |
loadRooms()
|
void |
processPacket(org.jivesoftware.smack.packet.Packet packet)
|
void |
removeChatSession(java.lang.String participant)
Removes the ChatSession associated with the participant. |
GroupChatSession |
removeGroupChatSession(java.lang.String roomName)
Removes the GroupChatSession associated with the room. |
void |
setActivityTime()
|
void |
setNickname(java.lang.String nickname)
|
void |
setPassword(java.lang.String password)
|
void |
setUsername(java.lang.String username)
|
void |
setXMPPConnection(org.jivesoftware.smack.XMPPConnection con)
Set's the XMPPConnection for this session. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public UserSession()
Method Detail |
---|
public void addGroupChatSession(java.lang.String roomName, GroupChatSession chatSession)
GroupChatSession
identified by the room name.
roomName
- the name of the room the GroupChatSession was created for.chatSession
- the GroupChatSession
that should be added.public GroupChatSession getGroupChatSession(java.lang.String roomName)
GroupChatSession
associated with the room.
roomName
- the name of the room.
public java.util.Map getAllSessions()
public GroupChatSession removeGroupChatSession(java.lang.String roomName)
GroupChatSession
associated with the room.
roomName
- the name of the room the GroupChatSession
was
created for.
GroupChatSession
that was removed.public void closeAndRemoveGroupChatSession(java.lang.String roomName)
GroupChatSession
roomName
- the room to close and remove.public void addChatSession(java.lang.String participant, ChatSession chatSession)
ChatSession
associated with a 1-to-1 converstation.
participant
- the participant the ChatSession
was created for.chatSession
- the ChatSession
created.public void removeChatSession(java.lang.String participant)
ChatSession
associated with the participant.
participant
- the participant the 1-to-1 session was created for.public ChatSession getChatSession(java.lang.String participant)
ChatSession
associated with a 1-to-1 chat.
participant
- the participant the ChatSession
was created for.
ChatSession
associated with this participant.public void destroyAllSessions()
public void setXMPPConnection(org.jivesoftware.smack.XMPPConnection con)
XMPPConnection
for this session.
con
- the XMPPConnection
to set.public org.jivesoftware.smack.XMPPConnection getXMPPConnection()
public void processPacket(org.jivesoftware.smack.packet.Packet packet)
processPacket
in interface org.jivesoftware.smack.PacketListener
public boolean checkForInvalidSession()
public void setActivityTime()
public boolean isActive()
public void loadRooms()
public java.util.List getAvailableRooms()
public RoomInfo getRoomInfo(java.lang.String roomJID)
public void closeConnection()
public java.util.Map getPrivateMessageMap()
public java.lang.String getPassword()
public void setPassword(java.lang.String password)
public java.lang.String getNickname()
public void setNickname(java.lang.String nickname)
public java.lang.String getUsername()
public void setUsername(java.lang.String username)
public boolean isAnonymous()
|
Jive Forums Project Page | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |