reSIProcate
SIP stack, Dialog Usage Manager and related libraries
Loading...
Searching...
No Matches
mohparkserver::Server Class Reference

#include <Server.hxx>

Inheritance diagram for mohparkserver::Server:
[legend]

Public Member Functions

 Server (ConfigParser &config)
 
virtual ~Server ()
 
void initializeResipLogging (unsigned int maxByteCount, const resip::Data &level, const resip::Data &resipFilename)
 
void startup ()
 Starts the recon thread(s).
 
void process (int timeoutMs)
 This should be called in a loop to give process cycles to the server.
 
void shutdown ()
 Used to initiate a shutdown of the server.
 
recon::UserAgent * getMyUserAgent ()
 
MOHManager & getMOHManager ()
 
ParkManager & getParkManager ()
 
void getActiveCallsInfo (CallInfoList &callInfos)
 
virtual void onMaxParkTimeout (recon::ParticipantHandle participantHandle)
 
- Public Member Functions inherited from recon::ConversationManager
 ConversationManager (std::shared_ptr< MediaStackAdapter > mediaStackAdapter, std::shared_ptr< resip::ConfigParse > configParse=std::shared_ptr< resip::ConfigParse >())
 
virtual ~ConversationManager ()
 
virtual ConversationHandle createConversation (AutoHoldMode autoHoldMode=AutoHoldEnabled)
 Create a new empty Conversation to which participants can be added.
 
virtual void destroyConversation (ConversationHandle convHandle)
 Destroys an existing Conversation, and ends all participants that solely belong to this conversation.
 
virtual void joinConversation (ConversationHandle sourceConvHandle, ConversationHandle destConvHandle)
 Joins all participants from source conversation into destination conversation and destroys source conversation.
 
virtual ParticipantHandle createRemoteParticipant (ConversationHandle convHandle, const resip::NameAddr &destination, ParticipantForkSelectMode forkSelectMode=ForkSelectAutomatic, const std::shared_ptr< ConversationProfile > &conversationProfile=nullptr, const std::multimap< resip::Data, resip::Data > &extraHeaders=std::multimap< resip::Data, resip::Data >())
 Creates a new remote participant in the specified conversation that is attempted to be reached at the specified address.
 
virtual ParticipantHandle createRemoteIMPagerParticipant (const resip::NameAddr &destination, const std::shared_ptr< ConversationProfile > &conversationProfile=nullptr)
 Creates a new remote IM participant that will be attempted to be reached when sendIMToParticipant is called.
 
virtual ParticipantHandle createRemoteIMSessionParticipant (const resip::NameAddr &destination, ParticipantForkSelectMode forkSelectMode=ForkSelectAutomatic, const std::shared_ptr< ConversationProfile > &callerProfile=nullptr, const std::multimap< resip::Data, resip::Data > &extraHeaders=std::multimap< resip::Data, resip::Data >())
 Creates a new remote IM participant that will attempted to be reached immediately at the specified address.
 
virtual ParticipantHandle createMediaResourceParticipant (ConversationHandle convHandle, const resip::Uri &mediaUrl, const std::shared_ptr< resip::Data > &playAudioBuffer=std::shared_ptr< resip::Data >(), void *recordingCircularBuffer=0)
 Creates a new media resource participant in the specified conversation.
 
virtual ParticipantHandle createLocalParticipant ()
 Creates a new local participant in the specified conversation (if supported).
 
virtual void destroyParticipant (ParticipantHandle partHandle)
 Ends connections to the participant and removes it from all active conversations.
 
virtual void addParticipant (ConversationHandle convHandle, ParticipantHandle partHandle)
 Adds the specified participant to the specified conversation.
 
virtual void removeParticipant (ConversationHandle convHandle, ParticipantHandle partHandle)
 Removed the specified participant from the specified conversation.
 
virtual void moveParticipant (ParticipantHandle partHandle, ConversationHandle sourceConvHandle, ConversationHandle destConvHandle)
 Removed the specified participant from the specified conversation.
 
virtual void modifyParticipantContribution (ConversationHandle convHandle, ParticipantHandle partHandle, unsigned int inputGain, unsigned int outputGain)
 Modifies how the participant contributes to the particular conversation.
 
virtual void modifyParticipantRecordChannel (ParticipantHandle partHandle, unsigned int channelNum)
 If the participant is mixed to a multi-channel recording resource, then this controls if a participants audio is mixed into channel 1 or channel 2.
 
virtual void outputBridgeMatrix (ConversationHandle convHandle=0)
 Logs a multiline representation of the current state of the mixing matrix.
 
virtual void alertParticipant (ParticipantHandle partHandle, bool earlyFlag=true)
 Signal to the participant that it should provide ringback.
 
virtual void answerParticipant (ParticipantHandle partHandle)
 Signal to the participant that the call is answered.
 
virtual void rejectParticipant (ParticipantHandle partHandle, unsigned int rejectCode)
 Rejects an incoming remote participant with the specified code.
 
virtual void redirectParticipant (ParticipantHandle partHandle, const resip::NameAddr &destination, unsigned int redirectCode=302, RedirectSuccessCondition successCondition=RedirectSuccessOnConnected)
 Redirects the participant to another endpoint.
 
virtual void redirectToParticipant (ParticipantHandle partHandle, ParticipantHandle destPartHandle, RedirectSuccessCondition successCondition=RedirectSuccessOnConnected)
 This is used for attended transfer scenarios where both participants are no longer managed by the conversation manager - for SIP this will send a REFER with embedded Replaces header.
 
virtual void holdParticipant (ParticipantHandle partHandle, bool hold)
 Manually puts a paricipant on hold, or takes off hold without needing to move it in and out of any conversations.
 
virtual void sendIMToParticipant (ParticipantHandle partHandle, std::unique_ptr< resip::Contents > contents)
 Sends a MESSAGE with specified Contents to RemoteParticipant, RemoteIMPagerParticipant, or a RemoteIMSessionParticipant.
 
virtual void addBufferToMediaResourceCache (const resip::Data &name, const resip::Data &buffer, int type)
 This function is used to add a chunk of memory to a media/prompt cache.
 
virtual bool getBufferFromMediaResourceCache (const resip::Data &name, resip::Data **buffer, int *type)
 This function is used to retrieve a chunk of memory from the media/prompt cache.
 
virtual void requestKeyframe (ParticipantHandle partHandle, std::chrono::duration< double > durationMs)
 
virtual void requestKeyframeFromPeer (ParticipantHandle partHandle, std::chrono::duration< double > durationMs)
 
virtual void requestKeyframeFromPeerRecurring (ParticipantHandle partHandle, std::chrono::duration< double > interval)
 
virtual void startApplicationTimer (unsigned int timerId, unsigned int timerData1, unsigned int timerData2, unsigned int durationMs)
 This function is used to start a timer on behalf of recon based application.
 
virtual void startApplicationTimer (unsigned int timerId, unsigned int timerData1, unsigned int timerData2, std::chrono::duration< double > duration)
 This function is used to start a timer on behalf of recon based application.
 
virtual void onApplicationTimer (unsigned int timerId, unsigned int timerData1, unsigned int timerData2)
 
virtual void onIncomingIMPagerParticipant (ParticipantHandle partHandle, const resip::SipMessage &msg, ConversationProfile &conversationProfile)
 Notifies an application about a new remote IM pager mode participant that has sent a message.
 
virtual void onIncomingIMSessionParticipant (ParticipantHandle partHandle, const resip::SipMessage &msg, bool autoAnswer, ConversationProfile &conversationProfile)
 Notifies an application about a new remote IM session mode participant that has sent an INVITE.
 
virtual bool onReceiveIMFromParticipant (ParticipantHandle partHandle, const resip::SipMessage &msg)
 Notifies an application about a subsequent message from remote and existing IM participant.
 
virtual void onParticipantSendIMFailure (ParticipantHandle partHandle, const resip::SipMessage &status, std::unique_ptr< resip::Contents > contents)
 Notifies an application that a send IM call has failed.
 
virtual void onParticipantTerminated (ParticipantHandle partHandle, unsigned int statusCode, const resip::Data &reason)
 Notifies an application about a disconnect by a remote participant.
 
virtual void onParticipantDestroyed (ParticipantHandle partHandle, ParticipantType partType)
 Notifies an application when a Participant has been destroyed.
 
virtual void onParticipantConnectedConfirmed (ParticipantHandle partHandle, const resip::SipMessage &msg)
 Notifies an application that an inbound remote participant call now fully connected after answering (ie: ACK was received).
 
virtual void onParticipantVoiceActivity (recon::ParticipantHandle partHandle, bool on, bool inbound)
 Notifies an application when voice activity is detected to on or off from a remote participant.
 
virtual void onMediaResourceParticipantFailed (ParticipantHandle partHandle)
 Notifies an application about a failure in a media resource participant.
 
virtual RemoteParticipant * createAppropriateRemoteParticipantInstance (resip::DialogUsageManager &dum, RemoteParticipantDialogSet &rpds)
 
virtual RemoteParticipant * createAppropriateRemoteParticipantInstance (ParticipantHandle partHandle, resip::DialogUsageManager &dum, RemoteParticipantDialogSet &rpds)
 
virtual RemoteParticipantDialogSet * createRemoteIMSessionParticipantDialogSetInstance (ConversationManager::ParticipantForkSelectMode forkSelectMode=ConversationManager::ForkSelectAutomatic, std::shared_ptr< ConversationProfile > conversationProfile=nullptr)
 
virtual void setMediaStackAdapter (std::shared_ptr< MediaStackAdapter > mediaStackAdapter)
 
MediaStackAdapter & getMediaStackAdapter ()
 
std::shared_ptr< resip::ConfigParse > getConfig ()
 
bool sendKeyframesAtStart () const
 
- Public Member Functions inherited from resip::InviteSessionHandler
 InviteSessionHandler (bool genericOfferAnswer=false)
 
virtual ~InviteSessionHandler ()
 
virtual bool isGenericOfferAnswer ()
 
virtual void onEarlyMedia (ClientInviteSessionHandle, const SipMessage &, const Contents &)
 
virtual void onPrack (ServerInviteSessionHandle, const SipMessage &msg)
 called when PRACK is received for a reliable provisional answer (UAS)
 
virtual void terminate (ClientInviteSessionHandle h)
 called when an early dialog decides it wants to terminate the dialog.
 
virtual void onReadyToSend (InviteSessionHandle, SipMessage &msg)
 called to allow app to adorn a message. default is to send immediately
 
virtual void onAnswer (InviteSessionHandle, const SipMessage &msg, const Contents &)
 
virtual void onOffer (InviteSessionHandle, const SipMessage &msg, const Contents &)
 
virtual void onRemoteAnswerChanged (InviteSessionHandle, const SipMessage &msg, const Contents &)
 
virtual void onAckReceived (InviteSessionHandle, const SipMessage &msg)
 called when ACK is received
 
virtual void onAckNotReceived (InviteSessionHandle)
 default behaviour is to send a BYE to end the dialog
 
virtual void onStaleReInviteTimeout (InviteSessionHandle h)
 UAC gets no final response within the stale re-invite timeout (default is 40 seconds).
 
virtual void onIllegalNegotiation (InviteSessionHandle, const SipMessage &msg)
 will be called if reINVITE or UPDATE in dialog fails
 
virtual void onSessionExpired (InviteSessionHandle)
 will be called if Session-Timers are used and Session Timer expires default behaviour is to send a BYE to send the dialog
 
virtual void onFlowTerminated (InviteSessionHandle)
 Called when a TCP or TLS flow to the server has terminated.
 
- Public Member Functions inherited from resip::DialogSetHandler
virtual ~DialogSetHandler ()
 
- Public Member Functions inherited from resip::OutOfDialogHandler
virtual ~OutOfDialogHandler ()
 
- Public Member Functions inherited from resip::ClientSubscriptionHandler
virtual ~ClientSubscriptionHandler ()
 
virtual void onReadyToSend (ClientSubscriptionHandle, SipMessage &msg)
 called to allow app to adorn a message.
 
virtual void onNotifyNotReceived (ClientSubscriptionHandle)
 
virtual void onFlowTerminated (ClientSubscriptionHandle)
 Called when a TCP or TLS flow to the server has terminated.
 
- Public Member Functions inherited from resip::ServerSubscriptionHandler
virtual ~ServerSubscriptionHandler ()
 
virtual void onPublished (ServerSubscriptionHandle associated, ServerPublicationHandle publication, const Contents *contents, const SecurityAttributes *attrs)
 
virtual void onNotifyAccepted (ServerSubscriptionHandle, const SipMessage &msg)
 
virtual void onFlowTerminated (ServerSubscriptionHandle)
 Called when a TCP or TLS flow to the server has terminated.
 
virtual void getExpires (const SipMessage &msg, uint32_t &expires, int &errorResponseCode)
 Default behavior is to use the expires value in the SipMessage, if it exists.
 
virtual bool hasMinExpires () const
 
virtual uint32_t getMinExpires () const
 
virtual bool hasMaxExpires () const
 
virtual uint32_t getMaxExpires () const
 
const Mimes & getSupportedMimeTypes () const
 
- Public Member Functions inherited from resip::RedirectHandler
virtual ~RedirectHandler ()
 
- Public Member Functions inherited from resip::ClientPagerMessageHandler
virtual ~ClientPagerMessageHandler ()
 
- Public Member Functions inherited from resip::ServerPagerMessageHandler
virtual ~ServerPagerMessageHandler ()
 

Public Attributes

ConfigParser & mConfig
 

Protected Member Functions

virtual void onConversationDestroyed (recon::ConversationHandle convHandle)
 Notifies an application when a conversation has been destroyed.
 
virtual void onParticipantDestroyed (recon::ParticipantHandle partHandle)
 Notifies an application when a Participant has been destroyed.
 
virtual void onDtmfEvent (recon::ParticipantHandle partHandle, int dtmf, int duration, bool up)
 Notifies an application when an RFC2833 DTMF event is received from a particular remote participant.
 
virtual void onIncomingParticipant (recon::ParticipantHandle partHandle, const resip::SipMessage &msg, bool autoAnswer, recon::ConversationProfile &conversationProfile)
 Notifies an application about a new remote participant that is attempting to contact it.
 
virtual void onRequestOutgoingParticipant (recon::ParticipantHandle partHandle, const resip::SipMessage &msg, recon::ConversationProfile &conversationProfile)
 Notifies an application about a new remote participant that is trying to be contacted.
 
virtual void onParticipantTerminated (recon::ParticipantHandle partHandle, unsigned int statusCode)
 Notifies an application about a disconnect by a remote participant.
 
virtual void onParticipantProceeding (recon::ParticipantHandle partHandle, const resip::SipMessage &msg)
 Notifies an application that a remote participant call attempt is proceeding at the first hop.
 
virtual void onRelatedConversation (recon::ConversationHandle relatedConvHandle, recon::ParticipantHandle relatedPartHandle, recon::ConversationHandle origConvHandle, recon::ParticipantHandle origPartHandle)
 Notifies an applications that a outbound remote participant request has forked.
 
virtual void onParticipantAlerting (recon::ParticipantHandle partHandle, const resip::SipMessage &msg)
 Notifies an application that a remote participant call attempt is alerting the remote party.
 
virtual void onParticipantConnected (recon::ParticipantHandle partHandle, const resip::SipMessage &msg)
 Notifies an application that a remote participant call attempt is now connected.
 
virtual void onParticipantRedirectSuccess (recon::ParticipantHandle partHandle)
 Notifies an application that a redirect request has succeeded.
 
virtual void onParticipantRedirectFailure (recon::ParticipantHandle partHandle, unsigned int statusCode)
 Notifies an application that a redirect request has failed.
 
virtual void onParticipantRequestedHold (recon::ParticipantHandle partHandle, bool held)
 
- Protected Member Functions inherited from recon::ConversationManager
virtual void onNewSession (resip::ClientInviteSessionHandle h, resip::InviteSession::OfferAnswerType oat, const resip::SipMessage &msg)
 called when an initial INVITE or the intial response to an outoing invite

 
virtual void onNewSession (resip::ServerInviteSessionHandle h, resip::InviteSession::OfferAnswerType oat, const resip::SipMessage &msg)
 
virtual void onFailure (resip::ClientInviteSessionHandle h, const resip::SipMessage &msg)
 Received a failure response from UAS.
 
virtual void onEarlyMedia (resip::ClientInviteSessionHandle, const resip::SipMessage &, const resip::SdpContents &)
 called when an in-dialog provisional response is received that contains a body
 
virtual void onProvisional (resip::ClientInviteSessionHandle, const resip::SipMessage &msg)
 called when dialog enters the Early state - typically after getting 18x
 
virtual void onConnected (resip::ClientInviteSessionHandle h, const resip::SipMessage &msg)
 called when a dialog initiated as a UAC enters the connected state
 
virtual void onConnected (resip::InviteSessionHandle, const resip::SipMessage &msg)
 called when a dialog initiated as a UAS enters the connected state
 
virtual void onConnectedConfirmed (resip::InviteSessionHandle, const resip::SipMessage &msg)
 called when ACK (with out an answer) is received for initial invite (UAS)
 
virtual void onStaleCallTimeout (resip::ClientInviteSessionHandle)
 UAC gets no final response within the stale call timeout (default is 3 minutes).
 
virtual void onTerminated (resip::InviteSessionHandle h, resip::InviteSessionHandler::TerminatedReason reason, const resip::SipMessage *msg)
 
virtual void onRedirected (resip::ClientInviteSessionHandle, const resip::SipMessage &msg)
 called when a 3xx with valid targets is encountered in an early dialog
This is different then getting a 3xx in onTerminated, as another request will be attempted, so the DialogSet will not be destroyed.
 
virtual void onAnswer (resip::InviteSessionHandle, const resip::SipMessage &msg, const resip::SdpContents &)
 called when an answer is received - has nothing to do with user answering the call

 
virtual void onOffer (resip::InviteSessionHandle handle, const resip::SipMessage &msg, const resip::SdpContents &offer)
 called when an offer is received - must send an answer soon after this
 
virtual void onOfferRequired (resip::InviteSessionHandle, const resip::SipMessage &msg)
 called when an Invite w/out offer is sent, or any other context which requires an offer from the user
 
virtual void onOfferRejected (resip::InviteSessionHandle, const resip::SipMessage *msg)
 called if an offer in a UPDATE or re-INVITE was rejected - not real useful.
 
virtual void onOfferRequestRejected (resip::InviteSessionHandle, const resip::SipMessage &msg)
 Called when an error response is received for a reinvite-nobody request (via requestOffer)
 
virtual void onRemoteSdpChanged (resip::InviteSessionHandle, const resip::SipMessage &msg, const resip::SdpContents &sdp)
 called when a modified body is received in a 2xx response to a session-timer reINVITE.
 
virtual void onInfo (resip::InviteSessionHandle, const resip::SipMessage &msg)
 called when INFO message is received the application must call acceptNIT() or rejectNIT() once it is ready for another message.
 
virtual void onInfoSuccess (resip::InviteSessionHandle, const resip::SipMessage &msg)
 called when response to INFO message is received
 
virtual void onInfoFailure (resip::InviteSessionHandle, const resip::SipMessage &msg)
 
virtual void onRefer (resip::InviteSessionHandle, resip::ServerSubscriptionHandle, const resip::SipMessage &msg)
 called when an REFER message is received.
 
virtual void onReferAccepted (resip::InviteSessionHandle, resip::ClientSubscriptionHandle, const resip::SipMessage &msg)
 called when an REFER message receives an accepted response
 
virtual void onReferRejected (resip::InviteSessionHandle, const resip::SipMessage &msg)
 called when an REFER message receives a failure response
 
virtual void onReferNoSub (resip::InviteSessionHandle, const resip::SipMessage &msg)
 
virtual void onMessage (resip::InviteSessionHandle, const resip::SipMessage &msg)
 called when MESSAGE message is received
 
virtual void onMessageSuccess (resip::InviteSessionHandle, const resip::SipMessage &msg)
 called when response to MESSAGE message is received
 
virtual void onMessageFailure (resip::InviteSessionHandle, const resip::SipMessage &msg)
 
virtual void onForkDestroyed (resip::ClientInviteSessionHandle)
 called when a fork that was created through a 1xx never receives a 2xx because another fork answered and this fork was canceled by a proxy.
 
virtual void onTrying (resip::AppDialogSetHandle, const resip::SipMessage &msg)
 
virtual void onNonDialogCreatingProvisional (resip::AppDialogSetHandle, const resip::SipMessage &msg)
 
virtual void onUpdatePending (resip::ClientSubscriptionHandle h, const resip::SipMessage &notify, bool outOfOrder)
 
virtual void onUpdateActive (resip::ClientSubscriptionHandle h, const resip::SipMessage &notify, bool outOfOrder)
 
virtual void onUpdateExtension (resip::ClientSubscriptionHandle, const resip::SipMessage &notify, bool outOfOrder)
 
virtual void onTerminated (resip::ClientSubscriptionHandle h, const resip::SipMessage *notify)
 
virtual void onNewSubscription (resip::ClientSubscriptionHandle h, const resip::SipMessage &notify)
 
virtual int onRequestRetry (resip::ClientSubscriptionHandle h, int retryMinimum, const resip::SipMessage &notify)
 
virtual void onNewSubscription (resip::ServerSubscriptionHandle, const resip::SipMessage &sub)
 
virtual void onNewSubscriptionFromRefer (resip::ServerSubscriptionHandle, const resip::SipMessage &sub)
 
virtual void onRefresh (resip::ServerSubscriptionHandle, const resip::SipMessage &sub)
 
virtual void onTerminated (resip::ServerSubscriptionHandle)
 
virtual void onReadyToSend (resip::ServerSubscriptionHandle, resip::SipMessage &)
 
virtual void onNotifyRejected (resip::ServerSubscriptionHandle, const resip::SipMessage &msg)
 
virtual void onError (resip::ServerSubscriptionHandle, const resip::SipMessage &msg)
 
virtual void onExpiredByClient (resip::ServerSubscriptionHandle, const resip::SipMessage &sub, resip::SipMessage &notify)
 
virtual void onExpired (resip::ServerSubscriptionHandle, resip::SipMessage &notify)
 
virtual bool hasDefaultExpires () const
 dcm! – a bit clunky, but really want these objects to not have state
 
virtual uint32_t getDefaultExpires () const
 
virtual void onSuccess (resip::ClientOutOfDialogReqHandle, const resip::SipMessage &response)
 
virtual void onFailure (resip::ClientOutOfDialogReqHandle, const resip::SipMessage &response)
 
virtual void onReceivedRequest (resip::ServerOutOfDialogReqHandle, const resip::SipMessage &request)
 
virtual void onRedirectReceived (resip::AppDialogSetHandle, const resip::SipMessage &response)
 
virtual bool onTryingNextTarget (resip::AppDialogSetHandle, const resip::SipMessage &request)
 
virtual void onSuccess (resip::ClientPagerMessageHandle, const resip::SipMessage &status)
 
virtual void onFailure (resip::ClientPagerMessageHandle, const resip::SipMessage &status, std::unique_ptr< resip::Contents > contents)
 kh!
 
virtual void onMessageArrived (resip::ServerPagerMessageHandle, const resip::SipMessage &message)
 
UserAgent * getUserAgent ()
 
ParticipantHandle getNewParticipantHandle ()
 
void post (resip::Message *message)
 
void post (resip::ApplicationMessage &message, std::chrono::duration< double > duration=std::chrono::milliseconds::zero())
 
virtual void setUserAgent (UserAgent *userAgent)
 
std::shared_ptr< BridgeMixer > & getBridgeMixer ()
 
ConversationHandle getNewConversationHandle ()
 
Conversation * getConversation (ConversationHandle convHandle)
 
std::set< ConversationHandle > getConversationHandles () const
 
std::set< ParticipantHandle > getParticipantHandlesByType (ParticipantType participantType) const
 
bool isShuttingDown ()
 
bool remoteParticipantInitialHold ()
 
const std::vector< int > & keyframeIntervals () const
 

Friends

class MOHManager
 
class ParkManager
 

Additional Inherited Members

- Public Types inherited from recon::ConversationManager
enum  ParticipantType {
  ParticipantType_Local , ParticipantType_Remote , ParticipantType_MediaResource , ParticipantType_RemoteIMPager ,
  ParticipantType_RemoteIMSession
}
 
enum  ParticipantForkSelectMode { ForkSelectAutomatic , ForkSelectManual , ForkSelectAutomaticEx }
 
enum  AutoHoldMode { AutoHoldDisabled , AutoHoldEnabled , AutoHoldBroadcastOnly }
 
enum  RedirectSuccessCondition { RedirectSuccessOnTrying , RedirectSuccessOnRinging , RedirectSuccessOnConnected }
 
- Public Types inherited from resip::InviteSessionHandler
enum  TerminatedReason {
  Error , Timeout , Replaced , LocalBye ,
  RemoteBye , LocalCancel , RemoteCancel , Rejected ,
  Referred
}
 called when an dialog enters the terminated state - this can happen after getting a BYE, Cancel, or 4xx,5xx,6xx response - or the session times out More...
 
- Static Public Member Functions inherited from recon::ConversationManager
static const char * participantTypeToString (ParticipantType partType)
 

Detailed Description

Definition at line 26 of file Server.hxx.

Constructor & Destructor Documentation

◆ Server()

mohparkserver::Server::Server ( ConfigParser &  config)

Definition at line 118 of file Server.cxx.

◆ ~Server()

mohparkserver::Server::~Server ( )
virtual

Definition at line 357 of file Server.cxx.

Member Function Documentation

◆ getActiveCallsInfo()

void mohparkserver::Server::getActiveCallsInfo ( CallInfoList &  callInfos)

Definition at line 479 of file Server.cxx.

◆ getMOHManager()

MOHManager & mohparkserver::Server::getMOHManager ( )
inline

Definition at line 63 of file Server.hxx.

◆ getMyUserAgent()

recon::UserAgent * mohparkserver::Server::getMyUserAgent ( )
inline

Definition at line 60 of file Server.hxx.

◆ getParkManager()

ParkManager & mohparkserver::Server::getParkManager ( )
inline

Definition at line 64 of file Server.hxx.

◆ initializeResipLogging()

void mohparkserver::Server::initializeResipLogging ( unsigned int  maxByteCount,
const resip::Data &  level,
const resip::Data &  resipFilename 
)

Definition at line 390 of file Server.cxx.

◆ onConversationDestroyed()

void mohparkserver::Server::onConversationDestroyed ( recon::ConversationHandle  convHandle)
protectedvirtual

Notifies an application when a conversation has been destroyed.


This is useful for tracking conversations that get created when forking occurs, and are destroyed when forked call is answered or ended.

Parameters
convHandleHandle of the destroyed conversation

Implements recon::ConversationManager.

Definition at line 499 of file Server.cxx.

◆ onDtmfEvent()

void mohparkserver::Server::onDtmfEvent ( recon::ParticipantHandle  partHandle,
int  dtmf,
int  duration,
bool  up 
)
protectedvirtual

Notifies an application when an RFC2833 DTMF event is received from a particular remote participant.

Parameters
partHandleHandle of the participant that received the digit
dtmfInteger representation of the DTMF tone received (from RFC2833 event codes)
durationDuration (in milliseconds) of the DTMF tone received
upSet to true if the DTMF key is up (otherwise down)

Implements recon::ConversationManager.

Definition at line 530 of file Server.cxx.

◆ onIncomingParticipant()

void mohparkserver::Server::onIncomingParticipant ( recon::ParticipantHandle  partHandle,
const resip::SipMessage &  msg,
bool  autoAnswer,
recon::ConversationProfile &  conversationProfile 
)
protectedvirtual

Notifies an application about a new remote participant that is attempting to contact it.

Parameters
partHandleHandle of the new incoming participant
msgIncludes information about the caller such as name and address
autoAnswerSet to true if auto answer has been requested

Implements recon::ConversationManager.

Definition at line 536 of file Server.cxx.

◆ onMaxParkTimeout()

void mohparkserver::Server::onMaxParkTimeout ( recon::ParticipantHandle  participantHandle)
virtual

Definition at line 647 of file Server.cxx.

◆ onParticipantAlerting()

void mohparkserver::Server::onParticipantAlerting ( recon::ParticipantHandle  partHandle,
const resip::SipMessage &  msg 
)
protectedvirtual

Notifies an application that a remote participant call attempt is alerting the remote party.


Parameters
partHandleHandle of the participant that is alerting
msgSIP message that caused the alerting

Implements recon::ConversationManager.

Definition at line 616 of file Server.cxx.

◆ onParticipantConnected()

void mohparkserver::Server::onParticipantConnected ( recon::ParticipantHandle  partHandle,
const resip::SipMessage &  msg 
)
protectedvirtual

Notifies an application that a remote participant call attempt is now connected.

Parameters
partHandleHandle of the participant that is connected
msgSIP message that caused the connection

Implements recon::ConversationManager.

Definition at line 622 of file Server.cxx.

◆ onParticipantDestroyed()

void mohparkserver::Server::onParticipantDestroyed ( recon::ParticipantHandle  partHandle)
protectedvirtual

Notifies an application when a Participant has been destroyed.

This is useful for tracking when audio playback via MediaResourceParticipants has stopped.

Parameters
partHandleHandle of the destroyed participant

Implements recon::ConversationManager.

Definition at line 505 of file Server.cxx.

◆ onParticipantProceeding()

void mohparkserver::Server::onParticipantProceeding ( recon::ParticipantHandle  partHandle,
const resip::SipMessage &  msg 
)
protectedvirtual

Notifies an application that a remote participant call attempt is proceeding at the first hop.

ie: SIP 100/trying

Parameters
partHandleHandle of the participant that is alerting
msgSIP message that caused the proceeding

Reimplemented from recon::ConversationManager.

Definition at line 602 of file Server.cxx.

◆ onParticipantRedirectFailure()

void mohparkserver::Server::onParticipantRedirectFailure ( recon::ParticipantHandle  partHandle,
unsigned int  statusCode 
)
protectedvirtual

Notifies an application that a redirect request has failed.


Indicates blind transfer or attended transfer status.

Parameters
partHandleHandle of the participant that was redirected

Implements recon::ConversationManager.

Definition at line 635 of file Server.cxx.

◆ onParticipantRedirectSuccess()

void mohparkserver::Server::onParticipantRedirectSuccess ( recon::ParticipantHandle  partHandle)
protectedvirtual

Notifies an application that a redirect request has succeeded.


Indicates blind transfer or attended transfer status.

Parameters
partHandleHandle of the participant that was redirected

Implements recon::ConversationManager.

Definition at line 628 of file Server.cxx.

◆ onParticipantRequestedHold()

void mohparkserver::Server::onParticipantRequestedHold ( recon::ParticipantHandle  partHandle,
bool  held 
)
protectedvirtual

Implements recon::ConversationManager.

Definition at line 641 of file Server.cxx.

◆ onParticipantTerminated()

void mohparkserver::Server::onParticipantTerminated ( recon::ParticipantHandle  partHandle,
unsigned int  statusCode 
)
protectedvirtual

Notifies an application about a disconnect by a remote participant.


For SIP this could be a BYE or a CANCEL request.

Parameters
partHandleHandle of the participant that terminated
statusCodeThe status Code for the termination.

Implements recon::ConversationManager.

Definition at line 596 of file Server.cxx.

◆ onRelatedConversation()

void mohparkserver::Server::onRelatedConversation ( recon::ConversationHandle  relatedConvHandle,
recon::ParticipantHandle  relatedPartHandle,
recon::ConversationHandle  origConvHandle,
recon::ParticipantHandle  origPartHandle 
)
protectedvirtual

Notifies an applications that a outbound remote participant request has forked.

A new Related Conversation and Participant are created.
Both new handles and original handles are conveyed to the application so it can track related conversations.

Parameters
relatedConvHandleHandle of newly created related conversation
relatedPartHandleHandle of the newly created related participant
origConvHandleHandle of the conversation that contained the participant that forked
origParticipantHandle of the participant that forked

Implements recon::ConversationManager.

Definition at line 608 of file Server.cxx.

◆ onRequestOutgoingParticipant()

void mohparkserver::Server::onRequestOutgoingParticipant ( recon::ParticipantHandle  partHandle,
const resip::SipMessage &  msg,
recon::ConversationProfile &  conversationProfile 
)
protectedvirtual

Notifies an application about a new remote participant that is trying to be contacted.

This event is required to notify the application if a call request has been initiated by a signaling mechanism other than the application, such as an out-of-dialog REFER request.

Parameters
partHandleHandle of the new remote participant
msgIncludes information about the destination requested to be attempted

Implements recon::ConversationManager.

Definition at line 566 of file Server.cxx.

◆ process()

void mohparkserver::Server::process ( int  timeoutMs)

This should be called in a loop to give process cycles to the server.

Parameters
timeoutMsWill return after timeoutMs if nothing to do. Application can do some work, but should call process again ASAP.

Definition at line 425 of file Server.cxx.

◆ shutdown()

void mohparkserver::Server::shutdown ( void  )

Used to initiate a shutdown of the server.

This function blocks until the shutdown is complete.

Note
There should not be an active process request when this is called.

Definition at line 432 of file Server.cxx.

◆ startup()

void mohparkserver::Server::startup ( )

Starts the recon thread(s).

Note
This should be called before calling process() in a loop

Definition at line 398 of file Server.cxx.

Friends And Related Symbol Documentation

◆ MOHManager

Definition at line 92 of file Server.hxx.

◆ ParkManager

Definition at line 93 of file Server.hxx.

Member Data Documentation

◆ mConfig

ConfigParser& mohparkserver::Server::mConfig

Definition at line 72 of file Server.hxx.


The documentation for this class was generated from the following files: