Jitsi: the OpenSource Java VoIP and Instant Messaging client.

net.java.sip.communicator.impl.protocol.zeroconf
Class OperationSetTypingNotificationsZeroconfImpl

java.lang.Object
  extended by net.java.sip.communicator.service.protocol.AbstractOperationSetTypingNotifications<ProtocolProviderServiceZeroconfImpl>
      extended by net.java.sip.communicator.impl.protocol.zeroconf.OperationSetTypingNotificationsZeroconfImpl
All Implemented Interfaces:
OperationSet, OperationSetTypingNotifications

public class OperationSetTypingNotificationsZeroconfImpl
extends AbstractOperationSetTypingNotifications<ProtocolProviderServiceZeroconfImpl>

Implements typing notifications for the Zeroconf protocol. The operation set would simply mirror all outgoing typing notifications and make them appear as incoming events generated by the contact that we are currently writing a message to.

Author:
Christian Vincenot, Maxime Catelin, Jonathan Martin

Field Summary
 
Fields inherited from class net.java.sip.communicator.service.protocol.AbstractOperationSetTypingNotifications
parentProvider
 
Fields inherited from interface net.java.sip.communicator.service.protocol.OperationSetTypingNotifications
STATE_PAUSED, STATE_STALE, STATE_STOPPED, STATE_TYPING, STATE_UNKNOWN
 
Constructor Summary
OperationSetTypingNotificationsZeroconfImpl(ProtocolProviderServiceZeroconfImpl provider)
          Creates a new instance of this operation set and keeps the parent provider as a reference.
 
Method Summary
 void sendTypingNotification(Contact notifiedContact, int typingState)
          Sends a notification to notifiedContatct that we have entered typingState.
 
Methods inherited from class net.java.sip.communicator.service.protocol.AbstractOperationSetTypingNotifications
addTypingNotificationsListener, assertConnected, fireTypingNotificationsEvent, removeTypingNotificationsListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OperationSetTypingNotificationsZeroconfImpl

OperationSetTypingNotificationsZeroconfImpl(ProtocolProviderServiceZeroconfImpl provider)
Creates a new instance of this operation set and keeps the parent provider as a reference.

Parameters:
provider - a ref to the ProtocolProviderServiceImpl that created us and that we'll use for retrieving the underlying aim connection.
Method Detail

sendTypingNotification

public void sendTypingNotification(Contact notifiedContact,
                                   int typingState)
                            throws IllegalStateException,
                                   IllegalArgumentException
Sends a notification to notifiedContatct that we have entered typingState.

Parameters:
notifiedContact - the Contact to notify
typingState - the typing state that we have entered.
Throws:
IllegalStateException - if the underlying stack is not registered and initialized.
IllegalArgumentException - if notifiedContact is not an instance belonging to the underlying implementation.

Jitsi: the OpenSource Java VoIP and Instant Messaging client.

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