H4502Handler Class Reference

#include <h450pdu.h>

Inheritance diagram for H4502Handler:

H450xHandler List of all members.

Public Types

enum  State {
  e_ctIdle, e_ctAwaitIdentifyResponse, e_ctAwaitInitiateResponse, e_ctAwaitSetupResponse,
  e_ctAwaitSetup, e_ctAwaitConnect
}

Public Member Functions

 H4502Handler (H323Connection &connection, H450xDispatcher &dispatcher)
virtual void AttachToSetup (H323SignalPDU &pdu)
virtual void AttachToAlerting (H323SignalPDU &pdu)
virtual void AttachToConnect (H323SignalPDU &pdu)
virtual void AttachToReleaseComplete (H323SignalPDU &pdu)
virtual PBoolean OnReceivedInvoke (int opcode, int invokeId, int linkedId, PASN_OctetString *argument)
virtual void OnReceivedCallTransferIdentify (int linkedId)
virtual void OnReceivedCallTransferAbandon (int linkedId)
virtual void OnReceivedCallTransferInitiate (int linkedId, PASN_OctetString *argument)
virtual void OnReceivedCallTransferSetup (int linkedId, PASN_OctetString *argument)
virtual void OnReceivedCallTransferUpdate (int linkedId, PASN_OctetString *argument)
virtual void OnReceivedSubaddressTransfer (int linkedId, PASN_OctetString *argument)
virtual void OnReceivedCallTransferComplete (int linkedId, PASN_OctetString *argument)
virtual void OnReceivedCallTransferActive (int linkedId, PASN_OctetString *argument)
virtual PBoolean OnReceivedReturnResult (X880_ReturnResult &returnResult)
void OnReceivedInitiateReturnResult ()
void OnReceivedSetupReturnResult ()
void OnReceivedIdentifyReturnResult (X880_ReturnResult &returnResult)
virtual PBoolean OnReceivedReturnError (int errorCode, X880_ReturnError &returnError)
void OnReceivedInitiateReturnError (const bool timerExpiry=false)
void OnReceivedSetupReturnError (int errorCode, const bool timerExpiry=false)
void OnReceivedIdentifyReturnError (const bool timerExpiry=false)
bool TransferCall (const PString &remoteParty, const PString &callIdentity)
void ConsultationTransfer (const PString &primaryCallToken)
void HandleConsultationTransfer (const PString &callIdentity, H323Connection &incoming)
void AwaitSetupResponse (const PString &token, const PString &identity)
State GetState () const
virtual void onReceivedAdmissionReject (const int returnError)
void HandleCallTransferFailure (const int returnError)
void StartctTimer (const PTimeInterval value)
void StopctTimer ()
PBoolean IsctTimerRunning ()
 PDECLARE_NOTIFIER (PTimer, H4502Handler, OnCallTransferTimeOut)
const H323ConnectiongetAssociatedConnection () const
void SetAssociatedCallToken (const PString &token)
const PString & getTransferringCallToken () const
void SetConsultationTransferSuccess ()
PBoolean isConsultationTransferSuccess ()

Protected Attributes

PString transferringCallToken
PString transferringCallIdentity
State ctState
PBoolean ctResponseSent
PTimer ctTimer
PString CallToken
PBoolean consultationTransfer

Member Enumeration Documentation

enum H4502Handler::State

Sub-state for call transfer.

Enumerator:
e_ctIdle 
e_ctAwaitIdentifyResponse 
e_ctAwaitInitiateResponse 
e_ctAwaitSetupResponse 
e_ctAwaitSetup 
e_ctAwaitConnect 


Constructor & Destructor Documentation

H4502Handler::H4502Handler ( H323Connection connection,
H450xDispatcher dispatcher 
)


Member Function Documentation

virtual void H4502Handler::AttachToSetup ( H323SignalPDU pdu  )  [virtual]

Reimplemented from H450xHandler.

virtual void H4502Handler::AttachToAlerting ( H323SignalPDU pdu  )  [virtual]

Reimplemented from H450xHandler.

virtual void H4502Handler::AttachToConnect ( H323SignalPDU pdu  )  [virtual]

Reimplemented from H450xHandler.

virtual void H4502Handler::AttachToReleaseComplete ( H323SignalPDU pdu  )  [virtual]

Reimplemented from H450xHandler.

virtual PBoolean H4502Handler::OnReceivedInvoke ( int  opcode,
int  invokeId,
int  linkedId,
PASN_OctetString *  argument 
) [virtual]

Parameters:
invokeId  InvokeId of operation (used in response)
linkedId  InvokeId of associated operation (if any)
argument  Parameters for the initiate operation

Implements H450xHandler.

virtual void H4502Handler::OnReceivedCallTransferIdentify ( int  linkedId  )  [virtual]

Handle an incoming Call Transfer Identify operation.

Parameters:
linkedId  InvokeId of associated operation (if any)

virtual void H4502Handler::OnReceivedCallTransferAbandon ( int  linkedId  )  [virtual]

Handle an incoming Call Transfer Abandon operation.

Parameters:
linkedId  InvokeId of associated operation (if any)

virtual void H4502Handler::OnReceivedCallTransferInitiate ( int  linkedId,
PASN_OctetString *  argument 
) [virtual]

Handle an incoming Call Transfer Initiate operation.

Parameters:
linkedId  InvokeId of associated operation (if any)
argument  Parameters for the initiate operation

virtual void H4502Handler::OnReceivedCallTransferSetup ( int  linkedId,
PASN_OctetString *  argument 
) [virtual]

Handle an incoming Call Transfer Setup operation.

Parameters:
linkedId  InvokeId of associated operation (if any)
argument  Parameters for the setup operation

virtual void H4502Handler::OnReceivedCallTransferUpdate ( int  linkedId,
PASN_OctetString *  argument 
) [virtual]

Handle an incoming Call Transfer Update operation.

Parameters:
linkedId  InvokeId of associated operation (if any)
argument  Parameters for the update operation

virtual void H4502Handler::OnReceivedSubaddressTransfer ( int  linkedId,
PASN_OctetString *  argument 
) [virtual]

Handle an incoming Subaddress Transfer operation.

Parameters:
linkedId  InvokeId of associated operation (if any)
argument  Parameters for the subaddress transfer operation

virtual void H4502Handler::OnReceivedCallTransferComplete ( int  linkedId,
PASN_OctetString *  argument 
) [virtual]

Handle an incoming Call Transfer Complete operation.

Parameters:
linkedId  InvokeId of associated operation (if any)
argument  Parameters for the complete operation

virtual void H4502Handler::OnReceivedCallTransferActive ( int  linkedId,
PASN_OctetString *  argument 
) [virtual]

Handle an incoming Call Transfer Active operation.

Parameters:
linkedId  InvokeId of associated operation (if any)
argument  Parameters for the active operation

virtual PBoolean H4502Handler::OnReceivedReturnResult ( X880_ReturnResult returnResult  )  [virtual]

Reimplemented from H450xHandler.

void H4502Handler::OnReceivedInitiateReturnResult (  ) 

Handle the reception of a callTransferInitiate returnResult when we are in call transfer state e_ctAwaitInitiateResponse. Note this is an internal function and it is not expected an application would use it.

void H4502Handler::OnReceivedSetupReturnResult (  ) 

Handle the reception of a callTransferSetup returnResult when we are in call transfer state e_ctAwaitSetupResponse. This funtion exists to handle the case when the transferred-to endpoint does not support H.450.2. Note this is an internal function and it is not expected an application would use it.

void H4502Handler::OnReceivedIdentifyReturnResult ( X880_ReturnResult returnResult  ) 

Handle the reception of a callTransferIdentify returnResult when we are in call transfer state e_ctAwaitIdentifyResponse. Note this is an internal function and it is not expected an application would use it.

virtual PBoolean H4502Handler::OnReceivedReturnError ( int  errorCode,
X880_ReturnError returnError 
) [virtual]

Reimplemented from H450xHandler.

void H4502Handler::OnReceivedInitiateReturnError ( const bool  timerExpiry = false  ) 

Handle the reception of a callTransferInitiate returnError or expiry of Call Transfer Timer CT-T3 when we are in call transfer state e_ctAwaitInitiateResponse. Note this is an internal function and it is not expected an application would use it.

Parameters:
timerExpiry  Flag to indicate expiry

void H4502Handler::OnReceivedSetupReturnError ( int  errorCode,
const bool  timerExpiry = false 
)

Handle the reception of a callTransferSetup returnError or expiry of Call Transfer Timer CT-T4 when we are in call transfer state e_ctAwaitSetupResponse. This funtion also additionally handles the case when the transferred-to endpoint does not support H.450.2 and has rejected the incoming call request. Note this is an internal function and it is not expected an application would use it.

Parameters:
timerExpiry  Flag to indicate expiry

void H4502Handler::OnReceivedIdentifyReturnError ( const bool  timerExpiry = false  ) 

Handle the reception of a callTransferIdentify returnError or expiry of Call Transfer Timer CT-T1 when we are in call transfer state e_ctAwaitIdentifyResponse. Note this is an internal function and it is not expected an application would use it.

Parameters:
timerExpiry  Flag to indicate expiry

bool H4502Handler::TransferCall ( const PString &  remoteParty,
const PString &  callIdentity 
)

Initiate the transfer of an existing call (connection) to a new remote party using H.450.2. This sends a Call Transfer Initiate Invoke message from the A-Party (transferring endpoint) to the B-Party (transferred endpoint).

Parameters:
remoteParty  Remote party to transfer the existing call to
callIdentity  Call Identity of secondary call if present

void H4502Handler::ConsultationTransfer ( const PString &  primaryCallToken  ) 

Transfer the call through consultation so the remote party in the primary call is connected to the called party in the second call using H.450.2. This sends a Call Transfer Identify Invoke message from the A-Party (transferring endpoint) to the C-Party (transferred-to endpoint).

Parameters:
primaryCallToken  Primary call

void H4502Handler::HandleConsultationTransfer ( const PString &  callIdentity,
H323Connection incoming 
)

Handle the reception of a callTransferSetupInvoke APDU whilst a secondary call exists.

Parameters:
callIdentity  Call Identity of secondary call
incoming  New incoming connection

void H4502Handler::AwaitSetupResponse ( const PString &  token,
const PString &  identity 
)

State H4502Handler::GetState (  )  const [inline]

Get the current call transfer state.

virtual void H4502Handler::onReceivedAdmissionReject ( const int  returnError  )  [virtual]

Handle the reception of an Admission Reject during a pending call transfer operation at the transferred endpoint. If the call transfer state of the current connection is e_ctAwaitSetupResponse, the stack attempts to find the existing connection between the transferred and transferring endpoints and inform this connection that a callTransferInitiateReturnError PDU needs to be sent. No action is taken if the current connection is not in call transfer state e_ctAwaitSetupResponse.

void H4502Handler::HandleCallTransferFailure ( const int  returnError  ) 

Handle the failure of a call transfer operation.

Parameters:
returnError  failure reason

void H4502Handler::StartctTimer ( const PTimeInterval  value  )  [inline]

Start the Call Transfer Timer using the specified time interval.

void H4502Handler::StopctTimer (  ) 

Stop the Call Transfer Timer

PBoolean H4502Handler::IsctTimerRunning (  )  [inline]

Is the Call Transfer Timer running?

H4502Handler::PDECLARE_NOTIFIER ( PTimer  ,
H4502Handler  ,
OnCallTransferTimeOut   
)

Callback mechanism for Call Transfer Timers CT-T1, CT-T2, CT-T3 & CT-T4

const H323Connection& H4502Handler::getAssociatedConnection (  )  const [inline]

Get the connection assoicated with this H4502Handler.

void H4502Handler::SetAssociatedCallToken ( const PString &  token  )  [inline]

Set the associated callToken.

const PString& H4502Handler::getTransferringCallToken (  )  const [inline]

Get the transferringCallToken member

void H4502Handler::SetConsultationTransferSuccess (  )  [inline]

Set the 'consultationTransfer' member to PTrue (indicating a successful transfer)

PBoolean H4502Handler::isConsultationTransferSuccess (  )  [inline]

Was the transfer through consultation successful.


Member Data Documentation

PString H4502Handler::transferringCallToken [protected]

PString H4502Handler::transferringCallIdentity [protected]

State H4502Handler::ctState [protected]

PBoolean H4502Handler::ctResponseSent [protected]

PTimer H4502Handler::ctTimer [protected]

PString H4502Handler::CallToken [protected]

PBoolean H4502Handler::consultationTransfer [protected]


The documentation for this class was generated from the following file:
Generated on Mon Sep 15 11:49:33 2008 for OPAL by  doxygen 1.5.1