CAF: Working With Caf Call Legs
Line 26: | Line 26: | ||
The call flow can perform various actions on each of it's call legs. Here is a list of the actions available on the CTBCAFCallLeg objects (please refer to the header files CTBCMCLeg.hpp for more information on each of these functions). | The call flow can perform various actions on each of it's call legs. Here is a list of the actions available on the CTBCAFCallLeg objects (please refer to the header files CTBCMCLeg.hpp for more information on each of these functions). | ||
− | + | === Controlling call flow: === | |
− | + | ||
- AcceptCall() | - AcceptCall() | ||
- AlertCall() | - AlertCall() | ||
Line 40: | Line 39: | ||
- CallTransferResponse() | - CallTransferResponse() | ||
− | + | === Playing/recording audio === | |
- PlayStream() | - PlayStream() | ||
- RecordStream() | - RecordStream() | ||
Line 47: | Line 46: | ||
- StopStream() | - StopStream() | ||
− | + | === Digits (tone) and events: === | |
- PlayDigit() | - PlayDigit() | ||
- StartDigitCollection() | - StartDigitCollection() | ||
Line 56: | Line 55: | ||
- StopEventCollection() | - StopEventCollection() | ||
− | + | === Controlling profile or stats: === | |
- SetProfile() | - SetProfile() | ||
- ChangeProfile() | - ChangeProfile() |
Revision as of 12:24, 7 April 2011
Contents |
Overview
CAF Call leg (CTBCAFCallLeg):
The CTBCAFCallLeg class is a wrapper around the CTBCMCLeg object. It's enhancing the CTBCMCLeg object so multiple call legs can be grouped and managed together from a parent Call object (CTBCAFCallFlow).
CAF Call Flow (CTBCAFCallFlow):
The CTBCAFCallFlow base class contains one or multiple CTBCAFCallLeg objects. The role of the CTBCAFCallFlow object is to implement a call flow that involves actions on legs that have a relation with each other.
CAF Call Bridge (CTBCAFBridge, based on CTBCAFCallFlow):
A typical implementation of a call flow is the CTBCAFBridge class (based on the CTBCAFCallFlow base class). This class is designed to - Receive an incoming call - Make a corresponding outgoing call - Join them together - Terminate both of them when one leg hangups.
CAF Call Behavior (CTBCAFCallBehavior):
Behaviors CTBCAFCallBehavior can be attached to a call flow (CTBCAFCallFlow). Their role is to modify the basic call flow, decorating it with optional functionality (CDR logging, FAX detection, Ring tone playback, etc.)
Actions on call legs
The call flow can perform various actions on each of it's call legs. Here is a list of the actions available on the CTBCAFCallLeg objects (please refer to the header files CTBCMCLeg.hpp for more information on each of these functions).
Controlling call flow:
- AcceptCall() - AlertCall() - AnswerCall() - ProgressCall() - SendCallSuppInfo() - Join() - Unjoin() - TerminateCall() - CallTransferRequest() - CallTransferProgress() - CallTransferResponse()
Playing/recording audio
- PlayStream() - RecordStream() - PauseStream() - ResumeStream() - StopStream()
Digits (tone) and events:
- PlayDigit() - StartDigitCollection() - StopDigitCollection() - PlayEvent() - CancelEvent() - StartEventCollection() - StopEventCollection()
Controlling profile or stats:
- SetProfile() - ChangeProfile() - GetStats()
States can be queried instantly:
IsTerminating() IsAccepted() IsAlerted() IsAnswered() IsSynchronized() IsJoined()
Call information can be queried instantly:
GetLegId() GetLinkId() GetAttributes() GetProfile() GetJoinAttributes()
Events received from call legs by the CTBCAFCallFlow object
Initialization and termination of call leg objects:
- OnInitIncomingCallLeg() - OnInitOutgoingCallLeg() - OnLegFreed()
Controlling call flow:
- OnCallLegAccepted() - OnCallLegAlerting() - OnCallLegAnswered() - OnCallLegSuppInfo() - OnLegJoinDone() - OnLegUnjoinDone() - OnCallLegTerminatingIndication() - OnCallLegTerminated() - OnLegTerminated() - OnCallLegTransferRequest() - OnCallLegTransferProgress() - OnCallLegTransferResponse()
Re-synchronization with toolpack_engine:
- OnSyncDone() - OnSyncLost()
Timers or custom events:
- OnLegEvent()
Errors detected by toolpack_engine:
- OnLegError()
Playing/recording audio
- OnStreamPlayingDone() - OnStreamRecordingDone()
Digits (tone) and events:
- OnDigitPlayingDone() - OnDigitCollected() - OnEventPlayingDone() - OnEventCollected()
Controlling profile or stats:
- OnLegProfileChanged() - OnLegStatsUpdated()