Jitsi: the OpenSource Java VoIP and Instant Messaging client.

net.java.sip.communicator.service.neomedia.control
Class KeyFrameControlAdapter

java.lang.Object
  extended by net.java.sip.communicator.service.neomedia.control.KeyFrameControlAdapter
All Implemented Interfaces:
KeyFrameControl

public class KeyFrameControlAdapter
extends Object
implements KeyFrameControl

Provides a default implementation of KeyFrameControl.

Author:
Lyubomir Marinov

Nested Class Summary
 
Nested classes/interfaces inherited from interface net.java.sip.communicator.service.neomedia.control.KeyFrameControl
KeyFrameControl.KeyFrameRequestee, KeyFrameControl.KeyFrameRequester
 
Constructor Summary
KeyFrameControlAdapter()
           
 
Method Summary
 void addKeyFrameRequestee(int index, KeyFrameControl.KeyFrameRequestee keyFrameRequestee)
          Implements KeyFrameControl.addKeyFrameRequestee(int, KeyFrameRequestee).
 void addKeyFrameRequester(int index, KeyFrameControl.KeyFrameRequester keyFrameRequester)
          Implements KeyFrameControl.addKeyFrameRequester(int, KeyFrameRequester).
 List<KeyFrameControl.KeyFrameRequestee> getKeyFrameRequestees()
          Implements KeyFrameControl.getKeyFrameRequestees().
 List<KeyFrameControl.KeyFrameRequester> getKeyFrameRequesters()
          Implements KeyFrameControl.getKeyFrameRequesters().
 boolean keyFrameRequest()
          Implements KeyFrameControl.keyFrameRequest().
 boolean removeKeyFrameRequestee(KeyFrameControl.KeyFrameRequestee keyFrameRequestee)
          Implements KeyFrameControl.removeKeyFrameRequestee(KeyFrameRequestee).
 boolean removeKeyFrameRequester(KeyFrameControl.KeyFrameRequester keyFrameRequester)
          Implements KeyFrameControl.removeKeyFrameRequester(KeyFrameRequester).
 boolean requestKeyFrame(boolean urgent)
          Implements KeyFrameControl.requestKeyFrame(boolean).
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

KeyFrameControlAdapter

public KeyFrameControlAdapter()
Method Detail

addKeyFrameRequestee

public void addKeyFrameRequestee(int index,
                                 KeyFrameControl.KeyFrameRequestee keyFrameRequestee)
Implements KeyFrameControl.addKeyFrameRequestee(int, KeyFrameRequestee). Adds a KeyFrameRequestee to be made available through this KeyFrameControl.

Specified by:
addKeyFrameRequestee in interface KeyFrameControl
Parameters:
index - the zero-based index at which keyFrameRequestee is to be added to the list of KeyFrameRequestees made available or -1 to have this KeyFrameControl choose at which index it is to be added in accord with its internal logic through this KeyFrameControl
keyFrameRequestee - the KeyFrameRequestee to be added to this KeyFrameControl so that it is made available through it

addKeyFrameRequester

public void addKeyFrameRequester(int index,
                                 KeyFrameControl.KeyFrameRequester keyFrameRequester)
Implements KeyFrameControl.addKeyFrameRequester(int, KeyFrameRequester). Adds a KeyFrameRequester to be made available through this KeyFrameControl.

Specified by:
addKeyFrameRequester in interface KeyFrameControl
Parameters:
index - the zero-based index at which keyFrameRequester is to be added to the list of KeyFrameRequesters made available or -1 to have this KeyFrameControl choose at which index it is to be added in accord with its internal logic through this KeyFrameControl
keyFrameRequester - the KeyFrameRequester to be added to this KeyFrameControl so that it is made available through it

getKeyFrameRequestees

public List<KeyFrameControl.KeyFrameRequestee> getKeyFrameRequestees()
Implements KeyFrameControl.getKeyFrameRequestees(). Gets the KeyFrameRequestees made available through this KeyFrameControl.

Specified by:
getKeyFrameRequestees in interface KeyFrameControl
Returns:
an unmodifiable list of KeyFrameRequestees made available through this KeyFrameControl

getKeyFrameRequesters

public List<KeyFrameControl.KeyFrameRequester> getKeyFrameRequesters()
Implements KeyFrameControl.getKeyFrameRequesters(). Gets the KeyFrameRequesters made available through this KeyFrameControl.

Specified by:
getKeyFrameRequesters in interface KeyFrameControl
Returns:
an unmodifiable list of KeyFrameRequesters made available through this KeyFrameControl

keyFrameRequest

public boolean keyFrameRequest()
Implements KeyFrameControl.keyFrameRequest(). Notifies this KeyFrameControl that the remote peer of the associated VideoMediaStream has requested a key frame from the local peer.

Specified by:
keyFrameRequest in interface KeyFrameControl
Returns:
true if the local peer has honored the request from the remote peer for a key frame; otherwise, false

removeKeyFrameRequestee

public boolean removeKeyFrameRequestee(KeyFrameControl.KeyFrameRequestee keyFrameRequestee)
Implements KeyFrameControl.removeKeyFrameRequestee(KeyFrameRequestee). Removes a KeyFrameRequestee to no longer be made available through this KeyFrameControl.

Specified by:
removeKeyFrameRequestee in interface KeyFrameControl
Parameters:
keyFrameRequestee - the KeyFrameRequestee to be removed from this KeyFrameControl so that it is no longer made available through it
Returns:
true if keyFrameRequestee was found in this KeyFrameControl; otherwise, false

removeKeyFrameRequester

public boolean removeKeyFrameRequester(KeyFrameControl.KeyFrameRequester keyFrameRequester)
Implements KeyFrameControl.removeKeyFrameRequester(KeyFrameRequester). Removes a KeyFrameRequester to no longer be made available through this KeyFrameControl.

Specified by:
removeKeyFrameRequester in interface KeyFrameControl
Parameters:
keyFrameRequester - the KeyFrameRequester to be removed from this KeyFrameControl so that it is no longer made available through it
Returns:
true if keyFrameRequester was found in this KeyFrameControl; otherwise, false

requestKeyFrame

public boolean requestKeyFrame(boolean urgent)
Implements KeyFrameControl.requestKeyFrame(boolean). Requests a key frame from the remote peer of the associated VideoMediaStream.

Specified by:
requestKeyFrame in interface KeyFrameControl
Parameters:
urgent - true if the caller has determined that the need for a key frame is urgent and should not obey all constraints with respect to time between two subsequent requests for key frames
Returns:
true if a key frame was indeed requested from the remote peer of the associated VideoMediaStream in response to the call; otherwise, false

Jitsi: the OpenSource Java VoIP and Instant Messaging client.

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