|
1 /* |
|
2 * Copyright (c) 2005 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 |
|
21 #ifndef CMCECOMRTPSOURCE_H |
|
22 #define CMCECOMRTPSOURCE_H |
|
23 |
|
24 #include <e32std.h> |
|
25 #include "mcecommediasource.h" |
|
26 |
|
27 //FORWARD DECLARATIONS |
|
28 |
|
29 class TRtpSourceContainer |
|
30 { |
|
31 public: |
|
32 TUint32 iSilenceTimer; |
|
33 TUint iToneFrequency; |
|
34 TUint iToneLength; |
|
35 }; |
|
36 |
|
37 /** |
|
38 * |
|
39 * |
|
40 * @lib |
|
41 */ |
|
42 class CMceComRtpSource: public CMceComMediaSource |
|
43 { |
|
44 |
|
45 public: // Constructors and destructor |
|
46 |
|
47 |
|
48 /** |
|
49 * Constructor |
|
50 */ |
|
51 static CMceComRtpSource* NewL(); |
|
52 |
|
53 /** |
|
54 * Constructor |
|
55 */ |
|
56 static CMceComRtpSource* NewLC(); |
|
57 |
|
58 /** |
|
59 * Destructor. |
|
60 */ |
|
61 ~CMceComRtpSource(); |
|
62 |
|
63 public: // from CMceComMediaSource |
|
64 |
|
65 /** |
|
66 * Internalizes flat data |
|
67 * @param aReadStream read stream |
|
68 */ |
|
69 void InternalizeFlatL( RReadStream& aReadStream ); |
|
70 |
|
71 /** |
|
72 * Externalizes flat data |
|
73 * @param aWriteStream write stream |
|
74 */ |
|
75 void ExternalizeFlatL( RWriteStream& aWriteStream ); |
|
76 |
|
77 /** |
|
78 * Traversal event handler |
|
79 * @param aEvent the event |
|
80 * @return status, if event was consumed or not or object needs update |
|
81 */ |
|
82 TInt EventReceivedL( TMceComEvent& aEvent ); |
|
83 |
|
84 /** |
|
85 * Clones this object |
|
86 * @return the cloned object |
|
87 */ |
|
88 CMceComMediaSource* CloneL(); |
|
89 |
|
90 /** |
|
91 * Updates this object |
|
92 * @param aUpdate object updates this |
|
93 */ |
|
94 void UpdateL( CMceComMediaSource& aUpdate ); |
|
95 |
|
96 public: // new functions |
|
97 |
|
98 /** |
|
99 * Return inactivity timer |
|
100 * @return inactivity timer |
|
101 */ |
|
102 TUint InactivityTimer() const; |
|
103 |
|
104 |
|
105 #ifdef MCE_COMMON_SERVER_SIDE |
|
106 |
|
107 /** |
|
108 * Returns mcc type for mcc endpoint |
|
109 * @return mcc type |
|
110 */ |
|
111 const TUid MccType(); |
|
112 |
|
113 /** |
|
114 * Returns init param for mcc endpoint |
|
115 * @return mcc type |
|
116 */ |
|
117 const TDesC8& InitParamL( const CMceComCodec& aCodec ); |
|
118 |
|
119 /** |
|
120 * Prepares this endpoint |
|
121 */ |
|
122 void PrepareL(); |
|
123 |
|
124 |
|
125 #endif//MCE_COMMON_SERVER_SIDE |
|
126 |
|
127 |
|
128 protected: |
|
129 |
|
130 /** |
|
131 * C++ default constructor. |
|
132 * @param type of source |
|
133 */ |
|
134 CMceComRtpSource(); |
|
135 |
|
136 /** |
|
137 * second-phase copy constructor |
|
138 */ |
|
139 void ConstructL( CMceComRtpSource& aSource ); |
|
140 |
|
141 |
|
142 public: // Owned data |
|
143 |
|
144 |
|
145 TUint32 iInactivityTimer; |
|
146 |
|
147 TUint iBufferLength; |
|
148 |
|
149 TUint iBufferTreshold; |
|
150 |
|
151 HBufC8* iTalkBurstIndicator; |
|
152 |
|
153 RArray<TUint> iNotSupported; |
|
154 |
|
155 /** |
|
156 * RTP CName |
|
157 */ |
|
158 HBufC8* iIdentity; |
|
159 |
|
160 private: |
|
161 |
|
162 HBufC8* iSettings; |
|
163 |
|
164 |
|
165 }; |
|
166 |
|
167 |
|
168 #endif |