Jitsi: the OpenSource Java VoIP and Instant Messaging client.

net.java.sip.communicator.impl.protocol.gibberish
Class OperationSetTypingNotificationsGibberishImpl

java.lang.Object
  extended by net.java.sip.communicator.service.protocol.AbstractOperationSetTypingNotifications<ProtocolProviderServiceGibberishImpl>
      extended by net.java.sip.communicator.impl.protocol.gibberish.OperationSetTypingNotificationsGibberishImpl
All Implemented Interfaces:
OperationSet, OperationSetTypingNotifications

public class OperationSetTypingNotificationsGibberishImpl
extends AbstractOperationSetTypingNotifications<ProtocolProviderServiceGibberishImpl>

Implements typing notifications for the Gibberish 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:
Emil Ivov

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
OperationSetTypingNotificationsGibberishImpl(ProtocolProviderServiceGibberishImpl provider, OperationSetPersistentPresenceGibberishImpl opSetPersPresence)
          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

OperationSetTypingNotificationsGibberishImpl

OperationSetTypingNotificationsGibberishImpl(ProtocolProviderServiceGibberishImpl provider,
                                             OperationSetPersistentPresenceGibberishImpl opSetPersPresence)
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.
opSetPersPresence - the currently valid OperationSetPersistentPresenceGibberishImpl instance.
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.