|
Jitsi: the OpenSource Java VoIP and Instant Messaging client. | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.java.sip.communicator.impl.protocol.jabber.WhiteboardSessionJabberImpl
public class WhiteboardSessionJabberImpl
A representation of a WhiteboardSession.
| Constructor Summary | |
|---|---|
WhiteboardSessionJabberImpl(ProtocolProviderServiceJabberImpl sourceProvider,
OperationSetWhiteboardingJabberImpl opSet)
WhiteboardSessionJabberImpl constructor. |
|
| Method Summary | |
|---|---|
void |
addWhiteboardChangeListener(WhiteboardChangeListener listener)
Adds a whiteboard change listener to this whiteboard so that it could receive events on new whiteboard participants, theme changes and others. |
void |
addWhiteboardObjectListener(WhiteboardObjectListener listener)
Registers listener so that it would receive events every time a new WhiteboardObject is received on this whiteboard. |
void |
addWhiteboardParticipant(WhiteboardParticipant wbParticipant)
Adds wbParticipant to the list of participants in this white-board. |
WhiteboardObject |
createWhiteboardObject(String name)
Create a WhiteboardObject instance with the specified type. |
void |
deleteWhiteboardObject(WhiteboardObject obj)
Sends a WhiteboardObject to delete and delete the local WhiteboardObject |
boolean |
equals(Object obj)
Compares the specified object with this whiteboard and returns true if it the specified object is an instance of a Whiteboard object and if the extending telephony protocol considers the whiteboards represented by both objects to be the same. |
void |
fireMessageEvent(EventObject evt)
Delivers the specified event to all registered message listeners. |
void |
fireWhiteboardChangeEvent(String type,
Object oldValue,
Object newValue)
Creates a WhiteboardChangeEvent with this class as sourceWhiteboard, and the specified eventID and old and new values and dispatches it on all currently registered listeners. |
void |
fireWhiteboardParticipantEvent(WhiteboardParticipant sourceWhiteboardParticipant,
int eventID)
Creates a WhiteboardParticipantEvent with sourceWhiteboardParticipant and eventID and dispatches it on all currently registered listeners. |
ProtocolProviderService |
getProtocolProvider()
Returns a reference to the ProtocolProviderService instance that created this whiteboard. |
WhiteboardSessionState |
getState()
Returns the state that this whiteboard is currently in. |
String[] |
getSupportedWhiteboardObjects()
Returns all the type of WhiteboardObject that this whiteboard support. |
String |
getWhiteboardID()
Returns the id of the specified Whiteboard. |
Vector<WhiteboardObject> |
getWhiteboardObjects()
Returns the WhiteboardObjects in this whiteboard session. |
Iterator<WhiteboardParticipant> |
getWhiteboardParticipants()
Returns an iterator over all white-board participants. |
int |
getWhiteboardParticipantsCount()
Returns the number of participants currently associated with this white-board session. |
WhiteboardSession |
getWhiteboardSession()
returns the current WhiteboardSession |
WhiteboardSessionState |
getWhiteboardSessionState()
Returns the state that this whiteboard is currently in. |
int |
hashCode()
Returns a hash code value for this whiteboard. |
void |
invite(String contactAddress)
Invites another user to this room. |
boolean |
isJoined()
Returns true if the local user is currently in the white-board session (after white-boarding one of the join() methods). |
boolean |
isOfflineMessagingSupported()
Determines wheter the protocol provider (or the protocol itself) support sending and receiving offline messages. |
boolean |
isParticipantContained(String participantName)
Checks if the participant given by participantName is contained in this white-board session. |
void |
join()
Joins this white-board with the nickname of the local user so that the user would start receiving events and WhiteboardObject for it. |
void |
join(byte[] password)
Joins this white-board so that the user would start receiving events and WhiteboardObject for it. |
void |
leave()
Leave this whiteboard. |
void |
moveWhiteboardObject(WhiteboardObject obj)
Sends a WhiteboardObject to modify and modifies the local WhiteboardObject |
void |
participantAddressChanged(WhiteboardParticipantChangeEvent evt)
Indicates that a change has occurred in the address of the source WhiteboardParticipant. |
void |
participantDisplayNameChanged(WhiteboardParticipantChangeEvent evt)
Indicates that a change has occurred in the display name of the source WhiteboardParticipant. |
void |
participantImageChanged(WhiteboardParticipantChangeEvent evt)
Indicates that a change has occurred in the image of the source WhiteboardParticipant. |
void |
participantStateChanged(WhiteboardParticipantChangeEvent evt)
Verifies whether the whiteboard participant has entered a state. |
void |
participantTransportAddressChanged(WhiteboardParticipantChangeEvent evt)
Indicates that a change has occurred in the transport address that we use to communicate with the participant. |
void |
removeWhiteboardChangeListener(WhiteboardChangeListener listener)
Removes listener to this whiteboard so that it won't receive further WhiteboardChangeEvents. |
void |
removeWhiteboardObjectListener(WhiteboardObjectListener listener)
Removes listener so that it won't receive any further WhiteboardObject events from this room. |
void |
removeWhiteboardParticipant(WhiteboardParticipant wbParticipant)
Removes whiteboardParticipant from the list of participants in this whiteboard. |
void |
sendWhiteboardObject(WhiteboardObject message)
Sends the message to the destination. |
void |
setState(WhiteboardSessionState newState)
Sets the state of this whiteboard |
void |
setWhiteboardSessionState(WhiteboardSessionState newState)
Sets the state of this whiteboard and fires a whiteboard change event notifying registered listeners for the change. |
String |
toString()
Returns a string textually representing this Whiteboard. |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public WhiteboardSessionJabberImpl(ProtocolProviderServiceJabberImpl sourceProvider,
OperationSetWhiteboardingJabberImpl opSet)
sourceProvider - Jabber protocol provideropSet - the whiteboard operation set| Method Detail |
|---|
public Iterator<WhiteboardParticipant> getWhiteboardParticipants()
getWhiteboardParticipants in interface WhiteboardSessionpublic int getWhiteboardParticipantsCount()
getWhiteboardParticipantsCount in interface WhiteboardSession
public void join()
throws OperationFailedException
join in interface WhiteboardSessionOperationFailedException - with the corresponding code if an error
occurs while joining the room.
public void join(byte[] password)
throws OperationFailedException
join in interface WhiteboardSessionpassword - the password to use when authenticating on the
white-board session.
OperationFailedException - with the corresponding code if an error
occurs while joining the room.public boolean isJoined()
join() methods).
isJoined in interface WhiteboardSessionpublic void leave()
leave in interface WhiteboardSessionpublic void invite(String contactAddress)
If the room is password-protected, the invitee will receive a password to use to join the room. If the room is members-only, the the invitee may be added to the member list.
invite in interface WhiteboardSessioncontactAddress - the address of the user to invite to the room.
(one may also invite users not on their contact list).public WhiteboardSession getWhiteboardSession()
public void participantStateChanged(WhiteboardParticipantChangeEvent evt)
participantStateChanged in interface WhiteboardParticipantListenerevt - The WhiteboardParticipantChangeEvent instance
containing the source event as well as its previous and its new status.public void participantDisplayNameChanged(WhiteboardParticipantChangeEvent evt)
participantDisplayNameChanged in interface WhiteboardParticipantListenerevt - The WhiteboardParticipantChangeEvent instance
containing the source event as well as its previous and its new display
names.public void participantAddressChanged(WhiteboardParticipantChangeEvent evt)
evt - The WhiteboardParticipantChangeEvent instance
containing the source event as well as its previous and its new address.public void participantTransportAddressChanged(WhiteboardParticipantChangeEvent evt)
evt - The WhiteboardParticipantChangeEvent instance
containing the source event as well as its previous and its new transport
address.public void participantImageChanged(WhiteboardParticipantChangeEvent evt)
participantImageChanged in interface WhiteboardParticipantListenerevt - The WhiteboardParticipantChangeEvent instance
containing the source event as well as its previous and its new image.public void addWhiteboardParticipant(WhiteboardParticipant wbParticipant)
addWhiteboardParticipant in interface WhiteboardSessionwbParticipant - the new WhiteboardParticipantpublic void removeWhiteboardParticipant(WhiteboardParticipant wbParticipant)
removeWhiteboardParticipant in interface WhiteboardSessionwbParticipant - the WhiteboardParticipant leaving the
whiteboard;public void setWhiteboardSessionState(WhiteboardSessionState newState)
newState - a reference to the WhiteboardState instance that
the whiteboard is to enter.public WhiteboardSessionState getWhiteboardSessionState()
public void addWhiteboardObjectListener(WhiteboardObjectListener listener)
addWhiteboardObjectListener in interface WhiteboardSessionlistener - a WhiteboardObjectListener that would be
notified every time a new WhiteboardObject
is received on this whiteboard.public void removeWhiteboardObjectListener(WhiteboardObjectListener listener)
removeWhiteboardObjectListener in interface WhiteboardSessionlistener - the WhiteboardObjectListener
to remove from this roompublic WhiteboardObject createWhiteboardObject(String name)
createWhiteboardObject in interface WhiteboardSessionname - the name of the object to create (should be one of the
WhiteboardObjectXXX.NAME fields).
public String getWhiteboardID()
getWhiteboardID in interface WhiteboardSessionpublic boolean isOfflineMessagingSupported()
public void moveWhiteboardObject(WhiteboardObject obj)
throws OperationFailedException
moveWhiteboardObject in interface WhiteboardSessionobj - the WhiteboardObject to send and modify
OperationFailedException - if sending
the WhiteboardObject fails for some reason.
public void deleteWhiteboardObject(WhiteboardObject obj)
throws OperationFailedException
deleteWhiteboardObject in interface WhiteboardSessionobj - the WhiteboardObject to send and delete
OperationFailedException - if sending
the WhiteboardObject fails for some reason.
public void sendWhiteboardObject(WhiteboardObject message)
throws OperationFailedException
sendWhiteboardObject in interface WhiteboardSessionmessage - the Message to send.
IllegalStateException - if the underlying stack is
not registered and initialized.
IllegalArgumentException - if to is not an
instance of ContactImpl.
OperationFailedException - if sending the WhiteboardObject fails
for some reason.public boolean equals(Object obj)
equals in class Objectobj - the whiteboard to compare this one with.
public int hashCode()
hashCode in class Objectpublic String toString()
toString in class Objectpublic void addWhiteboardChangeListener(WhiteboardChangeListener listener)
addWhiteboardChangeListener in interface WhiteboardSessionlistener - the listener to registerpublic void removeWhiteboardChangeListener(WhiteboardChangeListener listener)
removeWhiteboardChangeListener in interface WhiteboardSessionlistener - the listener to registerpublic ProtocolProviderService getProtocolProvider()
getProtocolProvider in interface WhiteboardSession
public void fireWhiteboardParticipantEvent(WhiteboardParticipant sourceWhiteboardParticipant,
int eventID)
sourceWhiteboardParticipant - the source
WhiteboardParticipant for the newly created event.eventID - the ID of the event to create (see CPE member ints)
public void fireWhiteboardChangeEvent(String type,
Object oldValue,
Object newValue)
type - the type of the event to create (see WhiteboardChangeEvent
member ints)oldValue - the value of the Whiteboard property that changed, before
the event had occurred.newValue - the value of the Whiteboard property that changed, after
the event has occurred.public Vector<WhiteboardObject> getWhiteboardObjects()
getWhiteboardObjects in interface WhiteboardSessionpublic void setState(WhiteboardSessionState newState)
setState in interface WhiteboardSessionnewState - a reference to the WhiteboardState instance that
the whiteboard is to enter.public WhiteboardSessionState getState()
getState in interface WhiteboardSessionpublic void fireMessageEvent(EventObject evt)
evt - the EventObject that we'd like delivered to all
registered message listeners.public String[] getSupportedWhiteboardObjects()
getSupportedWhiteboardObjects in interface WhiteboardSessionpublic boolean isParticipantContained(String participantName)
participantName - the name of the participant to search for
true if a participant with the given name is
contained in this session, false - otherwise
|
Jitsi: the OpenSource Java VoIP and Instant Messaging client. | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||