~ubuntu-branches/ubuntu/saucy/sflphone/saucy

« back to all changes in this revision

Viewing changes to sflphone-common/src/sip/sipcall.h

  • Committer: Bazaar Package Importer
  • Author(s): Francois Marier
  • Date: 2011-04-05 14:14:13 UTC
  • mfrom: (4.1.4 sid)
  • Revision ID: james.westby@ubuntu.com-20110405141413-hbwbunfsxpn2rtre
Tags: 0.9.13-1
* New upstream release
  - remove Debian patch (applied upstream)
* Fix watch file
* Remove unnecessary versioned dependency

Show diffs side-by-side

added added

removed removed

Lines of Context:
62
62
         * @param type  The type of the call. Could be Incoming
63
63
         *                                               Outgoing
64
64
         */
65
 
        SIPCall (const CallID& id, Call::CallType type, pj_pool_t *pool);
 
65
        SIPCall (const CallID& id, Call::CallType type, pj_caching_pool *caching_pool);
66
66
 
67
67
        /**
68
68
         * Destructor
69
69
         */
70
 
        ~SIPCall();
 
70
        ~SIPCall ();
71
71
 
72
72
        /**
73
73
         * Call Identifier
74
74
         * @return int  SIP call id
75
75
         */
76
 
        int  getCid() {
 
76
        int  getCid () {
77
77
            return _cid;
78
78
        }
79
79
 
82
82
         * @param cid SIP call id
83
83
         */
84
84
        void setCid (int cid) {
85
 
            _cid = cid ;
 
85
            _cid = cid;
86
86
        }
87
87
 
88
88
        /**
105
105
         * Transaction identifier
106
106
         * @return int  SIP transaction id
107
107
         */
108
 
        int  getTid() {
 
108
        int  getTid () {
109
109
            return _tid;
110
110
        }
111
111
 
112
 
 
113
 
 
114
 
 
115
112
        /**
116
113
         * Transaction identifier
117
114
         * @param tid SIP transaction id
120
117
            _tid = tid;
121
118
        }
122
119
 
 
120
        /**
 
121
         * Set event subscription internal structure
 
122
         */
123
123
        void setXferSub (pjsip_evsub* sub) {
124
124
            _xferSub = sub;
125
125
        }
126
126
 
 
127
        /**
 
128
         * Get event subscription internal structure
 
129
         */
127
130
        pjsip_evsub *getXferSub() {
128
131
            return _xferSub;
129
132
        }
136
139
            return _invSession;
137
140
        }
138
141
 
 
142
        void replaceInvSession (pjsip_inv_session *inv) {
 
143
                _invSession = inv;
 
144
        }
 
145
 
 
146
        /**
 
147
         * Return the local SDP session
 
148
         */
139
149
        Sdp* getLocalSDP (void) {
140
150
            return _local_sdp;
141
151
        }
142
152
 
 
153
        /**
 
154
         * Set the local SDP session
 
155
         */
143
156
        void setLocalSDP (Sdp *local_sdp) {
144
157
            _local_sdp = local_sdp;
145
158
        }
146
159
 
147
 
        /** Returns a pointer to the AudioRtp object */
 
160
        /**
 
161
         * Returns a pointer to the AudioRtp object
 
162
         */
148
163
        inline sfl::AudioRtpFactory * getAudioRtp (void) {
149
164
            return _audiortp;
150
165
        }
151
166
 
 
167
        /**
 
168
         * Return the local memory pool for this call
 
169
         */
 
170
        pj_pool_t *getMemoryPool(void) {
 
171
                return _pool;
 
172
        }
 
173
 
152
174
    private:
153
175
 
154
 
        int _cid;
155
 
        int _did;
156
 
        int _tid;
157
 
 
158
176
        // Copy Constructor
159
177
        SIPCall (const SIPCall& rh);
160
178
 
161
179
        // Assignment Operator
162
180
        SIPCall& operator= (const SIPCall& rh);
163
181
 
164
 
        /** Starting sound */
 
182
        /**
 
183
         * Call specific memory pool initialization size (based on empirical data)
 
184
         */
 
185
        static const int CALL_MEMPOOL_INIT_SIZE;
 
186
 
 
187
        /**
 
188
         * Call specific memory pool incrementation size
 
189
         */
 
190
        static const int CALL_MEMPOOL_INC_SIZE;
 
191
 
 
192
        /**
 
193
         * Call identifier
 
194
         */
 
195
        int _cid;
 
196
 
 
197
        /**
 
198
         * Domain identifier
 
199
         */
 
200
        int _did;
 
201
 
 
202
        /**
 
203
         * Transaction identifier
 
204
         */
 
205
        int _tid;
 
206
 
 
207
        /**
 
208
         * Audio Rtp Session factory
 
209
         */
165
210
        sfl::AudioRtpFactory * _audiortp;
166
211
 
 
212
        /**
 
213
         * Event subscription structure
 
214
         */
167
215
        pjsip_evsub *_xferSub;
168
216
 
 
217
        /**
 
218
         * The invite session to be reused in case of transfer
 
219
         */
169
220
        pjsip_inv_session *_invSession;
170
221
 
 
222
        /**
 
223
         * The SDP session
 
224
         */
171
225
        Sdp *_local_sdp;
172
226
 
 
227
        /**
 
228
         * The pool to allocate memory, released once call hang up
 
229
         */
 
230
        pj_pool_t *_pool;
 
231
 
173
232
};
174
233
 
175
234
#endif