rtpi.services.latejoin
Interface LateJoinRecipient


public abstract interface LateJoinRecipient
extends RtpiRecipient

This interface needs to be implemented by the application that employs the late join service. All messages of the base RTP/I session are forwarded unmodified and immediately to the application.

Author:
Juergen Vogel, Martin Mauve

Method Summary
 void lateJoinAskForPolicy(long subcomponentID)
          This method is called when the late join service discoveres a new subcomponent by receivin a RTCP/I SUBREP packet.
 void lateJoinFailed(long subcomponentID)
          This method is called when the late join service is unable to get the state of a subcomponent.
 void lateJoinGetState(long subcomponentID)
          This method is called when the late join service needs the state of a subcomponent, in order to help another late join service instance with the late join.
 void lateJoinReceiveState(Rtpi r, RtpiState state)
          This method is called when the late join service has successfully retrieved the state of a subcomponent.
 void lateJoinTerminated()
          This method is invoked when the late join has died unexpenctandly.
 
Methods inherited from interface rtpi.RtpiRecipient
activateSubcomponent, addSubcomponent, changeSourceInfo, connectionClosed, deactivateSubcomponent, receiveDeltaState, receiveEvent, receiveState, receiveStateQuery, removeSource, removeSubcomponent, rtpiAduLost, rtpiCouldNotRecover
 

Method Detail

lateJoinAskForPolicy

public void lateJoinAskForPolicy(long subcomponentID)
This method is called when the late join service discoveres a new subcomponent by receivin a RTCP/I SUBREP packet. The application is supposed to decide on the late join policy for that subcomponent can then call setPolicy on the late join service.
Parameters:
subcomponentID - The subcomponent ID of the subcomponent that has been discovered.

lateJoinFailed

public void lateJoinFailed(long subcomponentID)
This method is called when the late join service is unable to get the state of a subcomponent. This can happen when the subcomponent is no longer available at the time the late join service requests for the transmission of the subcomponent's state. It can also happen if no application is willing to extract the state of the subcomponent.
Parameters:
subcomponentID - The subcomponent ID of the subcomponent.

lateJoinGetState

public void lateJoinGetState(long subcomponentID)
This method is called when the late join service needs the state of a subcomponent, in order to help another late join service instance with the late join. If the join policy LateJoin.APPLICATION has been chosen then this will only be called when the application has claimed the responsibility of the subcomponent. If the join policy LateJoin.AUTOMATIC has been chosen, then the application may be selected to extract the state for late join purposes when it has received the state of that subcomponent. An application may ignore a lateJoinGetState message. However, the more applications ignore this message, the longer will it take to get the state for the latecomer. If a very large percentage of participants ignores this message, then the late join for that subcomponent may fail. If only one participant is able to reply to a state query then the join policy LateJoin.Application should be chosen. IF the application is able and willing to provide the state of the subcomponent, then it must tell the late join service that it will deliver the state by calling LateJoin.acknowledgeTransmitState. Then it may take some time to extract the state and finally it should deliver the state to the late join service by using LateJoin.transmitState.
Parameters:
subcomponentID - The subcomponent ID of the subcomponent.

lateJoinReceiveState

public void lateJoinReceiveState(Rtpi r,
                                 RtpiState state)
This method is called when the late join service has successfully retrieved the state of a subcomponent.
Parameters:
r - The RTP/I instance over which the state has been transmitted (this should be the late join RTP/I session)
state -  

lateJoinTerminated

public void lateJoinTerminated()
This method is invoked when the late join has died unexpenctandly.