25 namespace TMS { |
25 namespace TMS { |
26 |
26 |
27 // FORWARD DECLARATIONS |
27 // FORWARD DECLARATIONS |
28 class TMSClientSourceObserver; |
28 class TMSClientSourceObserver; |
29 class TMSBuffer; |
29 class TMSBuffer; |
|
30 class TMSGlobalContext; |
30 class TMSCallProxy; |
31 class TMSCallProxy; |
31 |
32 |
32 // TMSClientSourceBodyImpl class |
33 // TMSClientSourceBodyImpl class |
33 class TMSClientSourceBodyImpl : public TMSClientSourceBody, |
34 class TMSClientSourceBodyImpl : public TMSClientSourceBody, |
34 public MQueueHandlerObserver |
35 public MQueueHandlerObserver |
35 { |
36 { |
36 public: |
37 public: |
37 static gint Create(TMSClientSourceBody*& bodyimpl); |
38 static gint Create(TMSClientSourceBody*& bodyimpl); |
38 // From TMSClientSourceBody begins |
|
39 |
39 |
40 virtual ~TMSClientSourceBodyImpl(); |
40 virtual ~TMSClientSourceBodyImpl(); |
41 |
41 |
42 virtual gint AddObserver(TMSClientSourceObserver& obsrvr, |
42 virtual gint AddObserver(TMSClientSourceObserver& obsrvr, |
43 gpointer user_data); |
43 gpointer user_data); |
44 |
|
45 virtual gint RemoveObserver(TMSClientSourceObserver& obsrvr); |
44 virtual gint RemoveObserver(TMSClientSourceObserver& obsrvr); |
46 |
45 |
47 // In pull mode, client calls this.??? How to identify last buffer. |
46 // In pull mode, client calls this.??? How to identify last buffer. |
48 // Option 1 is to move setlast buffer to TMSBuffer interface. |
47 // Option 1 is to move setlast buffer to TMSBuffer interface. |
49 // Option 2 is to have overloaded function with another parameter. |
48 // Option 2 is to have overloaded function with another parameter. |
58 // Valid only when queue mode is set, otherwise no-op |
57 // Valid only when queue mode is set, otherwise no-op |
59 virtual gint Flush(); |
58 virtual gint Flush(); |
60 |
59 |
61 virtual gint GetType(TMSSourceType& sourcetype); |
60 virtual gint GetType(TMSSourceType& sourcetype); |
62 |
61 |
63 // From TMSClientSourceBody ends |
62 // From MQueueHandlerObserver |
|
63 virtual void QueueEvent(TInt aEventType, TInt aError, void* user_data); |
64 |
64 |
65 // From MQueueHandlerObserver starts |
65 void SetProxy(TMSGlobalContext* context, gpointer queuehandler); |
66 virtual void QueueEvent(TInt aEventType, TInt aError, void* user_data); |
|
67 // From MQueueHandlerObserver ends |
|
68 |
|
69 void SetProxy(TMSCallProxy* aProxy, gint strmid, gpointer queuehandler); |
|
70 |
66 |
71 private: |
67 private: |
72 TMSClientSourceBodyImpl(); |
68 TMSClientSourceBodyImpl(); |
73 gint PostConstruct(); |
69 gint PostConstruct(); |
74 |
70 |
75 private: |
71 private: |
76 TMSClientSourceObserver* iObserver; |
72 TMSClientSourceObserver* iObserver; |
77 gpointer iUserData; |
73 gpointer iUserData; |
|
74 TMSGlobalContext* iContext; |
78 TMSCallProxy* iProxy; |
75 TMSCallProxy* iProxy; |
79 gboolean iQueueMode; |
76 gboolean iQueueMode; |
80 gint iStreamId; |
|
81 }; |
77 }; |
82 |
78 |
83 } //namespace TMS |
79 } //namespace TMS |
84 |
80 |
85 #endif // TMS_CLIENT_SOURCE_BODY_IMPL_H |
81 #endif // TMS_CLIENT_SOURCE_BODY_IMPL_H |