Jitsi: the OpenSource Java VoIP and Instant Messaging client.

net.java.sip.communicator.service.protocol
Interface OperationSetWhiteboarding

All Superinterfaces:
OperationSet
All Known Implementing Classes:
OperationSetWhiteboardingJabberImpl

public interface OperationSetWhiteboarding
extends OperationSet

Provides basic functionality for white-board.

Author:
Julien Waechter

Method Summary
 void addInvitationListener(WhiteboardInvitationListener listener)
          Adds a listener to invitation notifications.
 void addInvitationRejectionListener(WhiteboardInvitationRejectionListener listener)
          Adds a listener to invitation notifications.
 void addPresenceListener(WhiteboardSessionPresenceListener listener)
          Adds a listener that will be notified of changes in our participation in a white-board session such as us being joined, left, dropped.
 WhiteboardSession createWhiteboardSession(String sessionName, Hashtable<Object,Object> sessionProperties)
          Creates a WhiteboardSession with the name sessionName and according to the specified sessionProperties.
 WhiteboardSession findWhiteboardSession(String sessionName)
          Returns a reference to a WhiteboardSession named sessionName or null if no such session exists.
 List<WhiteboardSession> getCurrentlyJoinedWhiteboards()
          Returns a list of the WhiteboardSessions that we have joined and are currently active in.
 List<WhiteboardSession> getCurrentlyJoinedWhiteboards(WhiteboardParticipant participant)
          Returns a list of the WhiteboardSessions that WhiteboardParticipant has joined and is currently active in.
 boolean isWhiteboardingSupportedByContact(Contact contact)
          Returns true if contact supports white-board sessions.
 void rejectInvitation(WhiteboardInvitation invitation, String rejectReason)
          Informs the sender of an invitation that we decline their invitation.
 void removeInvitationListener(WhiteboardInvitationListener listener)
          Removes listener from the list of invitation listeners registered to receive invitation events.
 void removeInvitationRejectionListener(WhiteboardInvitationRejectionListener listener)
          Removes the given listener from the list of invitation listeners registered to receive events every time an invitation has been rejected.
 void removePresenceListener(WhiteboardSessionPresenceListener listener)
          Removes a listener that was being notified of changes in our participation in a room such as us being kicked, joined, left.
 

Method Detail

getCurrentlyJoinedWhiteboards

List<WhiteboardSession> getCurrentlyJoinedWhiteboards()
Returns a list of the WhiteboardSessions that we have joined and are currently active in.

Returns:
a List of the WhiteboardSessions where the user has joined using a given connection.

getCurrentlyJoinedWhiteboards

List<WhiteboardSession> getCurrentlyJoinedWhiteboards(WhiteboardParticipant participant)
                                                      throws OperationFailedException,
                                                             OperationNotSupportedException
Returns a list of the WhiteboardSessions that WhiteboardParticipant has joined and is currently active in.

Parameters:
participant - the participant whose current WhiteboardSessions we will be querying.
Returns:
a list of the WhiteboardSessions that WhiteboardParticipant has joined and is currently active in.
Throws:
OperationFailedException - if an error occurs while trying to discover the session.
OperationNotSupportedException - if the server does not support white-boarding

createWhiteboardSession

WhiteboardSession createWhiteboardSession(String sessionName,
                                          Hashtable<Object,Object> sessionProperties)
                                          throws OperationFailedException,
                                                 OperationNotSupportedException
Creates a WhiteboardSession with the name sessionName and according to the specified sessionProperties. When the method returns the white-board session object, the local user will not have joined it and thus will not receive messages on it until the WhiteboardSession.join() method is called.

Parameters:
sessionName - the name of the WhiteboardSession to create.
sessionProperties - properties specifying how the session should be created.
Returns:
the newly created WhiteboardSession named sessionName.
Throws:
OperationFailedException - if the room couldn't be created for some reason (e.g. room already exists; user already joined to an existent room or user has no permissions to create a chat room).
OperationNotSupportedException - if chat room creation is not supported by this server

findWhiteboardSession

WhiteboardSession findWhiteboardSession(String sessionName)
                                        throws OperationFailedException,
                                               OperationNotSupportedException
Returns a reference to a WhiteboardSession named sessionName or null if no such session exists.

Parameters:
sessionName - the name of the WhiteboardSession that we're looking for.
Returns:
the WhiteboardSession named sessionName or null if no such session exists on the server that this provider is currently connected to.
Throws:
OperationFailedException - if an error occurs while trying to discover the white-board session on the server.
OperationNotSupportedException - if the server does not support white-boarding

rejectInvitation

void rejectInvitation(WhiteboardInvitation invitation,
                      String rejectReason)
Informs the sender of an invitation that we decline their invitation.

Parameters:
invitation - the invitation we are rejecting.
rejectReason - the reason to reject the invitation (optional)

addInvitationListener

void addInvitationListener(WhiteboardInvitationListener listener)
Adds a listener to invitation notifications. The listener will be fired anytime an invitation is received.

Parameters:
listener - an invitation listener.

removeInvitationListener

void removeInvitationListener(WhiteboardInvitationListener listener)
Removes listener from the list of invitation listeners registered to receive invitation events.

Parameters:
listener - the invitation listener to remove.

addInvitationRejectionListener

void addInvitationRejectionListener(WhiteboardInvitationRejectionListener listener)
Adds a listener to invitation notifications. The listener will be fired anytime an invitation is received.

Parameters:
listener - an invitation listener.

removeInvitationRejectionListener

void removeInvitationRejectionListener(WhiteboardInvitationRejectionListener listener)
Removes the given listener from the list of invitation listeners registered to receive events every time an invitation has been rejected.

Parameters:
listener - the invitation listener to remove.

isWhiteboardingSupportedByContact

boolean isWhiteboardingSupportedByContact(Contact contact)
Returns true if contact supports white-board sessions.

Parameters:
contact - reference to the contact whose support for white-boards we are currently querying.
Returns:
a boolean indicating whether contact supports white-boards.

addPresenceListener

void addPresenceListener(WhiteboardSessionPresenceListener listener)
Adds a listener that will be notified of changes in our participation in a white-board session such as us being joined, left, dropped.

Parameters:
listener - a local user participation listener.

removePresenceListener

void removePresenceListener(WhiteboardSessionPresenceListener listener)
Removes a listener that was being notified of changes in our participation in a room such as us being kicked, joined, left.

Parameters:
listener - a local user participation listener.

Jitsi: the OpenSource Java VoIP and Instant Messaging client.

Jitsi, the OpenSource Java VoIP and Instant Messaging client.
Distributable under LGPL license.