|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
public interface IMsnActivitySession
Allows the client to open Activity Sessions with users. An Activity may be a game (like Tic Tac Toe) or other application (such as Calendar Sharing).
IMsnActivitySession session = msnClient.getActivityService().createSession("recipient@hotmail.com", 10331358, "Tic Tac Toe Classic");
session.addActivitySessionListener(myActivitySessionListener);
session.invite();
Note: Tic Tac Toe Classic is just one of the many applications that run on top of Activity Sessions. This API allows you to create sessions and send/receive session commands. No application code is provided for specific applications such as Tic Tac Toe.
| Method Summary | |
|---|---|
void |
accept()
Accepts the incoming invitation and initiates this Activity Session. |
void |
addActivitySessionListener(IMsnActivitySessionListener listener)
Registers a listener to receive events from this session. |
void |
close()
Closes this Activity Session. |
void |
decline()
Declines the incoming invitation. |
int |
getAppId()
Returns the ID of the application being used in this Activity. |
String |
getAppName()
Returns the name of the application being used in this Activity. |
IMsnClient |
getClient()
Returns the client associated with this Activity. |
String |
getParticipant()
Returns the participant (end user) in this Activity. |
void |
invite()
Invites the participant (recipient) to this Activity Session. |
boolean |
isOnline()
Returns true if the session is connected and ready. |
boolean |
isOutgoing()
Returns true if this is an outgoing session (meaning the client sent the invitation). |
void |
removeActivitySessionListener(IMsnActivitySessionListener listener)
Stops a listener from receiving events from this session. |
void |
sendCommand(String command)
Sends a command to this Activity Session. |
| Method Detail |
|---|
int getAppId()
String getAppName()
IMsnClient getClient()
String getParticipant()
boolean isOutgoing()
void addActivitySessionListener(IMsnActivitySessionListener listener)
void removeActivitySessionListener(IMsnActivitySessionListener listener)
boolean isOnline()
void invite()
throws IOException
IOException - if isOutgoing() == false, or there was a problem
communicating with the server
void accept()
throws IOException
IOException - if isOutgoing() == true, or there was a problem
communicating with the server
void decline()
throws IOException
IOException - if isOutgoing() == true, or there was a problem
communicating with the server
void sendCommand(String command)
throws IOException
IOException - if there was a problem communicating with the servervoid close()
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||