1 /* |
|
2 * Copyright (c) 2007-2008 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: Provides implementation class for CCallInformation -class. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef CCALLINFORMATIONIMPL_H_ |
|
20 #define CCALLINFORMATIONIMPL_H_ |
|
21 |
|
22 #include <e32base.h> |
|
23 #include "mcall.h" |
|
24 |
|
25 // forward declarations |
|
26 class MCallInformationObserver; |
|
27 class CCallInfoIter; |
|
28 class CCallInfos; |
|
29 |
|
30 |
|
31 /** |
|
32 * This class provides implementation for CCallInformation -class. |
|
33 * |
|
34 * @lib telephonyservice.lib |
|
35 * @since S60 v5.1 |
|
36 */ |
|
37 NONSHARABLE_CLASS( CCallInformationImpl ) : public CBase |
|
38 { |
|
39 public: |
|
40 |
|
41 /** |
|
42 * Two-phased constructor. |
|
43 */ |
|
44 static CCallInformationImpl* NewL(); |
|
45 |
|
46 |
|
47 /** |
|
48 * Destructor. |
|
49 */ |
|
50 virtual ~CCallInformationImpl(); |
|
51 |
|
52 /** |
|
53 * Sets the observer for changes in current calls. |
|
54 * |
|
55 * @since S60 v5.1 |
|
56 * @param aObserver Observer for notifications. |
|
57 */ |
|
58 void NotifyCallInformationChanges( MCallInformationObserver& aObserver ); |
|
59 |
|
60 /** |
|
61 * Used to cancel previously placed NotifyCallInformationChanges call. |
|
62 * |
|
63 * @since S60 v5.1 |
|
64 */ |
|
65 void CancelNotification(); |
|
66 |
|
67 /** |
|
68 * Gets the snapshot of ongoing calls. |
|
69 * |
|
70 * @since S60 v5.1 |
|
71 * @return Ongoing calls. |
|
72 */ |
|
73 CCallInfoIter& GetCallsL(); |
|
74 |
|
75 |
|
76 /** |
|
77 * Returns information whether call in given state exist. |
|
78 * |
|
79 * @since S60 v5.2 |
|
80 * @param aState Specifies a call state that is used as a search key. |
|
81 * @return ETrue if call in given state exist. |
|
82 */ |
|
83 TBool IsCallInState( CCPCall::TCallState aState ) const; |
|
84 |
|
85 protected: |
|
86 |
|
87 CCallInformationImpl(); |
|
88 |
|
89 protected: //data |
|
90 /** |
|
91 * Observer to be notified when call information changes |
|
92 * Not own. |
|
93 */ |
|
94 MCallInformationObserver* iObserver; |
|
95 |
|
96 private: // data |
|
97 |
|
98 CCallInfos* iInfos; |
|
99 CCallInfos* iInfosInState; |
|
100 CCallInfoIter* iCallIter; |
|
101 CCallInfoIter* iCallStateIter; |
|
102 }; |
|
103 |
|
104 |
|
105 #endif /*CCALLINFORMATIONIMPL_H_*/ |
|
106 |
|