| 
    OPAL
    Version 3.14.3
    
   | 
 
#include <h450pdu.h>


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 H323Connection & | getAssociatedConnection () const | 
| void | SetAssociatedCallToken (const PString &token) | 
| const PString & | getTransferringCallToken () const | 
| void | SetConsultationTransferSuccess () | 
| PBoolean | isConsultationTransferSuccess () | 
  Public Member Functions inherited from H450xHandler | |
| H450xHandler (H323Connection &connection, H450xDispatcher &dispatcher) | |
| virtual PBoolean | OnReceivedReject (int problemType, int problemNumber) | 
| void | SendReturnError (int returnError) | 
| void | SendGeneralReject (int problem) | 
| void | SendInvokeReject (int problem) | 
| void | SendReturnResultReject (int problem) | 
| void | SendReturnErrorReject (int problem) | 
| PBoolean | DecodeArguments (PASN_OctetString *argString, PASN_Object &argObject, int absentErrorCode) | 
| unsigned | GetInvokeId () const | 
Protected Attributes | |
| PString | transferringCallToken | 
| PString | transferringCallIdentity | 
| State | ctState | 
| PBoolean | ctResponseSent | 
| PTimer | ctTimer | 
| PString | CallToken | 
| PBoolean | consultationTransfer | 
  Protected Attributes inherited from H450xHandler | |
| H323EndPoint & | endpoint | 
| H323Connection & | connection | 
| H450xDispatcher & | dispatcher | 
| unsigned | currentInvokeId | 
| enum H4502Handler::State | 
| H4502Handler::H4502Handler | ( | H323Connection & | connection, | 
| H450xDispatcher & | dispatcher | ||
| ) | 
      
  | 
  virtual | 
Reimplemented from H450xHandler.
      
  | 
  virtual | 
Reimplemented from H450xHandler.
      
  | 
  virtual | 
Reimplemented from H450xHandler.
      
  | 
  virtual | 
Reimplemented from H450xHandler.
| void H4502Handler::AwaitSetupResponse | ( | const PString & | token, | 
| const PString & | identity | ||
| ) | 
| 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).
| primaryCallToken | Primary call | 
      
  | 
  inline | 
Get the connection assoicated with this H4502Handler.
References H450xHandler::connection.
      
  | 
  inline | 
Get the current call transfer state.
References ctState.
      
  | 
  inline | 
Get the transferringCallToken member
References transferringCallToken.
| void H4502Handler::HandleCallTransferFailure | ( | const int | returnError | ) | 
Handle the failure of a call transfer operation.
| returnError | failure reason | 
| void H4502Handler::HandleConsultationTransfer | ( | const PString & | callIdentity, | 
| H323Connection & | incoming | ||
| ) | 
Handle the reception of a callTransferSetupInvoke APDU whilst a secondary call exists.
| callIdentity | Call Identity of secondary call | 
| incoming | New incoming connection | 
      
  | 
  inline | 
Was the transfer through consultation successful.
References consultationTransfer.
      
  | 
  inline | 
Is the Call Transfer Timer running?
References ctTimer.
      
  | 
  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.
      
  | 
  virtual | 
Handle an incoming Call Transfer Abandon operation.
| linkedId | InvokeId of associated operation (if any) | 
      
  | 
  virtual | 
Handle an incoming Call Transfer Active operation.
| linkedId | InvokeId of associated operation (if any) | 
| argument | Parameters for the active operation | 
      
  | 
  virtual | 
Handle an incoming Call Transfer Complete operation.
| linkedId | InvokeId of associated operation (if any) | 
| argument | Parameters for the complete operation | 
      
  | 
  virtual | 
Handle an incoming Call Transfer Identify operation.
| linkedId | InvokeId of associated operation (if any) | 
      
  | 
  virtual | 
Handle an incoming Call Transfer Initiate operation.
| linkedId | InvokeId of associated operation (if any) | 
| argument | Parameters for the initiate operation | 
      
  | 
  virtual | 
Handle an incoming Call Transfer Setup operation.
| linkedId | InvokeId of associated operation (if any) | 
| argument | Parameters for the setup operation | 
      
  | 
  virtual | 
Handle an incoming Call Transfer Update operation.
| linkedId | InvokeId of associated operation (if any) | 
| argument | Parameters for the update operation | 
| 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.
| timerExpiry | Flag to indicate expiry | 
| 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.
| 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.
| timerExpiry | Flag to indicate expiry | 
| 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.
      
  | 
  virtual | 
| invokeId | InvokeId of operation (used in response) | 
| linkedId | InvokeId of associated operation (if any) | 
| argument | Parameters for the initiate operation | 
Implements H450xHandler.
      
  | 
  virtual | 
Reimplemented from H450xHandler.
      
  | 
  virtual | 
Reimplemented from H450xHandler.
| 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.
| timerExpiry | Flag to indicate expiry | 
| 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.
      
  | 
  virtual | 
Handle an incoming Subaddress Transfer operation.
| linkedId | InvokeId of associated operation (if any) | 
| argument | Parameters for the subaddress transfer operation | 
| H4502Handler::PDECLARE_NOTIFIER | ( | PTimer | , | 
| H4502Handler | , | ||
| OnCallTransferTimeOut | |||
| ) | 
Callback mechanism for Call Transfer Timers CT-T1, CT-T2, CT-T3 & CT-T4
      
  | 
  inline | 
Set the associated callToken.
References CallToken.
      
  | 
  inline | 
Set the 'consultationTransfer' member to true (indicating a successful transfer)
References consultationTransfer.
      
  | 
  inline | 
Start the Call Transfer Timer using the specified time interval.
References ctTimer.
| void H4502Handler::StopctTimer | ( | ) | 
Stop the Call Transfer Timer
| 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).
| remoteParty | Remote party to transfer the existing call to | 
| callIdentity | Call Identity of secondary call if present | 
      
  | 
  protected | 
Referenced by SetAssociatedCallToken().
      
  | 
  protected | 
Referenced by isConsultationTransferSuccess(), and SetConsultationTransferSuccess().
      
  | 
  protected | 
      
  | 
  protected | 
Referenced by GetState().
      
  | 
  protected | 
Referenced by IsctTimerRunning(), and StartctTimer().
      
  | 
  protected | 
      
  | 
  protected | 
Referenced by getTransferringCallToken().