~ubuntu-branches/ubuntu/saucy/resiprocate/saucy-proposed

« back to all changes in this revision

Viewing changes to resip/recon/UserAgentRegistration.hxx

  • Committer: Package Import Robot
  • Author(s): Daniel Pocock
  • Date: 2012-05-17 19:29:59 UTC
  • Revision ID: package-import@ubuntu.com-20120517192959-vv00m77isztdy64q
Tags: upstream-1.8.2
ImportĀ upstreamĀ versionĀ 1.8.2

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#if !defined(UserAgentRegistration_hxx)
 
2
#define UserAgentRegistration_hxx
 
3
 
 
4
#include <resip/dum/AppDialogSet.hxx>
 
5
#include <resip/dum/InviteSessionHandler.hxx>
 
6
#include <resip/dum/DialogSetHandler.hxx>
 
7
#include <resip/dum/SubscriptionHandler.hxx>
 
8
 
 
9
#include "UserAgent.hxx"
 
10
 
 
11
namespace resip
 
12
{
 
13
class DialogUsageManager;
 
14
class SipMessage;
 
15
}
 
16
 
 
17
namespace recon
 
18
{
 
19
class UserAgent;
 
20
 
 
21
/**
 
22
  This class is used to manage active SIP registrations.
 
23
 
 
24
  Author: Scott Godin (sgodin AT SipSpectrum DOT com)
 
25
*/
 
26
 
 
27
class UserAgentRegistration : public resip::AppDialogSet
 
28
{
 
29
   public:  
 
30
      UserAgentRegistration(UserAgent& userAgent, resip::DialogUsageManager& dum, unsigned int handle);  
 
31
      virtual ~UserAgentRegistration();
 
32
 
 
33
      ConversationProfileHandle getConversationProfileHandle();
 
34
      virtual void end();
 
35
 
 
36
      const resip::NameAddrs& getContactAddresses();
 
37
 
 
38
      // Registration Handler ////////////////////////////////////////////////////////
 
39
      virtual void onSuccess(resip::ClientRegistrationHandle h, const resip::SipMessage& response);
 
40
      virtual void onFailure(resip::ClientRegistrationHandle h, const resip::SipMessage& response);
 
41
      virtual void onRemoved(resip::ClientRegistrationHandle h, const resip::SipMessage& response);
 
42
      virtual int onRequestRetry(resip::ClientRegistrationHandle h, int retryMinimum, const resip::SipMessage& msg);
 
43
 
 
44
   private:       
 
45
      UserAgent &mUserAgent;
 
46
      resip::DialogUsageManager &mDum;
 
47
      ConversationProfileHandle mConversationProfileHandle;
 
48
      bool mEnded;
 
49
      resip::ClientRegistrationHandle mRegistrationHandle;  
 
50
};
 
51
 
 
52
}
 
53
 
 
54
#endif
 
55
 
 
56
 
 
57
/* ====================================================================
 
58
 
 
59
 Copyright (c) 2007-2008, Plantronics, Inc.
 
60
 All rights reserved.
 
61
 
 
62
 Redistribution and use in source and binary forms, with or without
 
63
 modification, are permitted provided that the following conditions are 
 
64
 met:
 
65
 
 
66
 1. Redistributions of source code must retain the above copyright 
 
67
    notice, this list of conditions and the following disclaimer. 
 
68
 
 
69
 2. Redistributions in binary form must reproduce the above copyright
 
70
    notice, this list of conditions and the following disclaimer in the
 
71
    documentation and/or other materials provided with the distribution. 
 
72
 
 
73
 3. Neither the name of Plantronics nor the names of its contributors 
 
74
    may be used to endorse or promote products derived from this 
 
75
    software without specific prior written permission. 
 
76
 
 
77
 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 
 
78
 "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 
 
79
 LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 
 
80
 A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 
 
81
 OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 
 
82
 SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 
 
83
 LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 
 
84
 DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 
 
85
 THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 
 
86
 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 
 
87
 OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
88
 
 
89
 ==================================================================== */