|
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 CMCECOMMEDIASINK_H |
|
22 #define CMCECOMMEDIASINK_H |
|
23 |
|
24 #include "mcemediasink.h" |
|
25 #include "mcecomendpoint.h" |
|
26 |
|
27 // CONSTANTS |
|
28 const TMceSinkType KMceEmptySink = 100; |
|
29 const TMceEndpointCategory KMceCategorySink = 2; |
|
30 |
|
31 #ifdef MCE_COMMON_SERVER_SIDE |
|
32 |
|
33 class CMceMediaManager; |
|
34 |
|
35 #endif//MCE_COMMON_SERVER_SIDE |
|
36 |
|
37 class TMceComSinkFactory; |
|
38 class CMceComCodec; |
|
39 |
|
40 |
|
41 /** |
|
42 * |
|
43 * |
|
44 * @lib |
|
45 */ |
|
46 class CMceComMediaSink : public CMceComEndpoint |
|
47 { |
|
48 |
|
49 public: // Constructors and destructor |
|
50 |
|
51 /** |
|
52 * Constructor |
|
53 */ |
|
54 static CMceComMediaSink* NewL(); |
|
55 |
|
56 /** |
|
57 * Constructor |
|
58 */ |
|
59 static CMceComMediaSink* NewLC(); |
|
60 |
|
61 /** |
|
62 * Desctructor |
|
63 */ |
|
64 ~CMceComMediaSink(); |
|
65 |
|
66 public: // from CMceComEndpoint |
|
67 |
|
68 |
|
69 /** |
|
70 * Internalizes flat data |
|
71 * @param aReadStream read stream |
|
72 */ |
|
73 void InternalizeFlatL( RReadStream& aReadStream ); |
|
74 |
|
75 /** |
|
76 * Externalizes flat data |
|
77 * @param aWriteStream write stream |
|
78 */ |
|
79 void ExternalizeFlatL( RWriteStream& aWriteStream ); |
|
80 |
|
81 /** |
|
82 * Traversal event handler |
|
83 * @param aEvent the event |
|
84 * @return status, if event was consumed or not or object needs update |
|
85 */ |
|
86 TInt EventReceivedL( TMceComEvent& aEvent ); |
|
87 |
|
88 |
|
89 public: // virtual functions |
|
90 |
|
91 /** |
|
92 * Updates this object |
|
93 * @param aUpdate object updates this |
|
94 */ |
|
95 virtual void UpdateL( CMceComMediaSink& aUpdate ); |
|
96 |
|
97 /** |
|
98 * Clones this object |
|
99 * @return the cloned object |
|
100 */ |
|
101 virtual CMceComMediaSink* CloneL(); |
|
102 |
|
103 |
|
104 public: // new functions |
|
105 |
|
106 /** |
|
107 * Factory |
|
108 * @return factory |
|
109 */ |
|
110 static TMceComSinkFactory Factory(); |
|
111 |
|
112 #ifdef MCE_COMMON_SERVER_SIDE |
|
113 |
|
114 /** |
|
115 * Sets SSRC |
|
116 * @param aSSRC SSRC |
|
117 */ |
|
118 virtual void SetSSRC( TUint32 aSSRC ); |
|
119 |
|
120 /** |
|
121 * Returns mcc type for mcc endpoint |
|
122 * @return mcc type |
|
123 */ |
|
124 const TUid MccType(); |
|
125 |
|
126 #endif//MCE_COMMON_SERVER_SIDE |
|
127 |
|
128 |
|
129 protected: |
|
130 |
|
131 /** |
|
132 * C++ default constructor. |
|
133 * @param type of sink |
|
134 */ |
|
135 CMceComMediaSink( TMceSinkType aType ); |
|
136 |
|
137 |
|
138 }; |
|
139 |
|
140 |
|
141 #endif |