21 |
21 |
22 // USER |
22 // USER |
23 #include "musengmcesession.h" |
23 #include "musengmcesession.h" |
24 |
24 |
25 |
25 |
|
26 // FORWARD DECLARATIONS |
|
27 class CSIPProfile; |
|
28 class CMusSipProfileHandler; |
|
29 class MMusEngOutSessionObserver; |
26 |
30 |
27 // CLASS DECLARATION |
31 // CLASS DECLARATION |
28 /** |
32 /** |
29 * Class for handling MCE out sessions. Direct inherit classes are |
33 * Class for handling MCE out sessions. Direct inherit classes are |
30 * CMusEngLiveSession and CMusEngClipSession. |
34 * CMusEngLiveSession and CMusEngClipSession. |
31 * |
35 * |
32 * @lib musengine.lib |
36 * @lib musengine.lib |
|
37 * @since S60 v3.2 |
33 */ |
38 */ |
34 class CMusEngMceOutSession : public CMusEngMceSession |
39 class CMusEngMceOutSession : public CMusEngMceSession |
35 { |
40 { |
36 |
41 |
37 public: |
42 public: |
38 |
43 |
39 /** |
44 /** |
40 * Destructor |
45 * Destructor |
|
46 * |
|
47 * @since S60 v3.2 |
41 */ |
48 */ |
42 ~CMusEngMceOutSession(); |
49 ~CMusEngMceOutSession(); |
|
50 |
|
51 |
|
52 public: // NEW API FUNCTIONS |
|
53 |
|
54 /** |
|
55 * Sends invite to specified address |
|
56 * @leave KErrAlreadyExists if session establishment is already |
|
57 * in progress |
|
58 * |
|
59 * @since S60 v3.2 |
|
60 */ |
|
61 IMPORT_C void InviteL( const TDesC& aRecipient ); |
|
62 |
|
63 /** |
|
64 * Cancels Invite. |
|
65 * @pre Invite is sent. |
|
66 * @since S60 v3.2 |
|
67 */ |
|
68 IMPORT_C void CancelInviteL( ); |
|
69 |
|
70 |
|
71 public: // VIRTUAL API |
|
72 |
|
73 /** |
|
74 * Resumes previously paused session. Exact behavior depends on |
|
75 * exact session type. |
|
76 * |
|
77 * @since S60 v3.2 |
|
78 */ |
|
79 IMPORT_C virtual void PlayL() = 0; |
|
80 |
|
81 /** |
|
82 * Pauses session. Exact behavior depends on exact session type. |
|
83 * |
|
84 * @since S60 v3.2 |
|
85 */ |
|
86 IMPORT_C virtual void PauseL() = 0; |
|
87 |
|
88 |
|
89 protected: // Must be implemented in derived class |
|
90 |
|
91 /** |
|
92 * |
|
93 * @since S60 v3.2 |
|
94 */ |
|
95 virtual void CompleteSessionStructureL() = 0; |
|
96 |
|
97 |
|
98 protected: // helper function inherited from CMusEngMceSession |
|
99 |
|
100 /** |
|
101 * Function handling MCE session termination. |
|
102 * |
|
103 * @since S60 v3.2 |
|
104 */ |
|
105 //void HandleTermination( TMceTransactionDataContainer* aContainer ); |
43 |
106 |
44 |
107 |
45 protected: |
108 protected: |
46 |
109 |
47 /** |
110 /** |
48 * Constructor |
111 * Constructor |
|
112 * |
|
113 * @since S60 v3.2 |
49 */ |
114 */ |
50 CMusEngMceOutSession( const TRect& aRect ); |
115 CMusEngMceOutSession( const TRect& aRect, TUint aSipProfileId = 0 ); |
51 |
116 |
52 /** |
117 /** |
53 * Second-phase constructor |
118 * Second-phase constructor |
|
119 * |
|
120 * @since S60 v3.2 |
54 */ |
121 */ |
55 void ConstructL(); |
122 void ConstructL(); |
56 |
123 |
|
124 |
|
125 protected: // HELPERS |
|
126 |
|
127 #if (defined (__WINS__) || defined(__WINSCW__)) |
|
128 /** |
|
129 * |
|
130 * @since S60 v3.2 |
|
131 */ |
|
132 void SipProfileChanged(); |
|
133 #endif |
|
134 |
|
135 |
|
136 private: |
|
137 |
|
138 /** |
|
139 * |
|
140 * @since S60 v3.2 |
|
141 */ |
|
142 void CreateMceSessionStructureL(); |
|
143 |
|
144 /** |
|
145 * |
|
146 * @since S60 v3.2 |
|
147 */ |
|
148 MMusEngOutSessionObserver* OutSessionObserver(); |
|
149 |
|
150 /** |
|
151 * Parses, validates and creates new recipient address |
|
152 * out of given address. |
|
153 * @return Parsed recipient URI. Ownership is transferred. |
|
154 * @since S60 v3.2 |
|
155 */ |
|
156 HBufC8* ParseRecipientUriL( const TDesC& aRecipient ); |
|
157 |
|
158 |
|
159 protected: // DATA |
|
160 |
|
161 /** |
|
162 * Repository id of SipProfile |
|
163 * |
|
164 * @since S60 v3.2 |
|
165 */ |
|
166 TUint iSipProfileId; |
|
167 |
|
168 /** |
|
169 * Owned by iSipProfileHandler |
|
170 * |
|
171 * @since S60 v3.2 |
|
172 */ |
|
173 //CSIPProfile* iSipProfile; |
|
174 |
|
175 /** |
|
176 * Callback pointer to interface |
|
177 * |
|
178 * @since S60 v3.2 |
|
179 */ |
|
180 //CMusSipProfileHandler* iSipProfileHandler; |
|
181 |
|
182 |
|
183 public: // DATA |
|
184 |
|
185 /** |
|
186 * |
|
187 * @since S60 v3.2 |
|
188 */ |
|
189 HBufC8* iRecipient; |
|
190 TBool iInvited; |
|
191 |
57 }; |
192 }; |
58 #endif //MUSHENGMCESESSION_H |
193 #endif //MUSHENGMCESESSION_H |