|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface IPresenceService
This service should be used it there is a need to set a new status.
Also through this service the client can add user to be monitored of changing it's status. It can also remove user from being monitored and the client will no longer be notified if user changes it's status.
In addition, by using this interface the client can block the user and in this case it will no longer receive any kind of notification from it including new messages.
Created on 2004-11-27
| Method Summary | |
|---|---|
void |
addMonitoredUser(IUser user)
Adds the user to be monitored. |
void |
addUserListener(UserListener userListener)
Adds UserListener to the list of listeners
that will be notified of status related events. |
void |
changeMonitoredUserStatus(IUser user)
Changes status of the currently monitored user. |
java.util.Collection |
getMonitoredUsers()
Returns collections of the users that are currently being monitored. |
ILocalStatus |
getStatus()
Returns the actual status of the user that is logged in. |
void |
removeMonitoredUser(IUser user)
Remove the user that was previously being monitored. |
void |
removeUserListener(UserListener userListener)
Removes UserListener from the list of listeners that will
be notified of status related events. |
void |
setStatus(ILocalStatus localStatus)
Invocation of this method tries to set a new status of the user that is currently logged in. |
| Method Detail |
|---|
void setStatus(ILocalStatus localStatus)
throws GGException
localStatus - the new status to be set.
GGException - if there is an error while setting status.
GGSessionException - if user is not logged in.
java.lang.NullPointerException - if status is null.ILocalStatus getStatus()
void addMonitoredUser(IUser user)
throws GGException
After adding the user UserListener's will
receive events related to changing status of the user.
Note that you can also block the user using this method. After blocking the user you will no longer receive any messages from him/her.
user - that will be monitored or blocked.
GGException - if there is an error while adding user to be monitored.
GGSessionException - if we are currently not logged in to the Gadu-Gadu server.
java.lang.NullPointerException - if user is null.
void removeMonitoredUser(IUser user)
throws GGException
user - that we want to unregister from being monitored.
GGException - if there is an error while removing user from being monitored or if the user is not being monitored.
GGSessionException - if we are currently not logged in to the Gadu-Gadu server
java.lang.NullPointerException - if the user is null.
void changeMonitoredUserStatus(IUser user)
throws GGException
user - that contains a new status to be changed.
GGException - if there is an error while changing status of the user or if the user is not being monitored.
GGSessionException - if we are currently not logged in to the Gadu-Gadu server.java.util.Collection getMonitoredUsers()
void addUserListener(UserListener userListener)
UserListener to the list of listeners
that will be notified of status related events.
userListener - the UserListener object that will be notified.
java.lang.NullPointerException - if userListener is null.void removeUserListener(UserListener userListener)
UserListener from the list of listeners that will
be notified of status related events.
userListener - the UserListener object that will no longer be notified.
java.lang.NullPointerException - if userListener is null.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||