|
1 /* |
|
2 * Copyright (c) 2006 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: Refreshtimer. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 |
|
21 #ifndef simplesettings_H |
|
22 #define simplesettings_H |
|
23 |
|
24 #include <e32std.h> |
|
25 #include <s32file.h> |
|
26 |
|
27 // FORWARD DECLARATION |
|
28 class RFs; |
|
29 class RFileReadStream; |
|
30 class CRepository; |
|
31 |
|
32 |
|
33 //********************************** |
|
34 // TSimpleSettings |
|
35 //********************************** |
|
36 class TSimpleSettings |
|
37 { |
|
38 |
|
39 public: |
|
40 |
|
41 /** |
|
42 * Constructor |
|
43 */ |
|
44 TSimpleSettings( ); |
|
45 |
|
46 /** |
|
47 * Publish-expiry accessor |
|
48 * @return expiry in seconds |
|
49 */ |
|
50 TUint ExpiryPuhlish(); |
|
51 |
|
52 /** |
|
53 * Watcher-expiry accessor |
|
54 * @return expiry in seconds |
|
55 */ |
|
56 TUint ExpiryWatcher(); |
|
57 |
|
58 /** |
|
59 * Api request expiry accessor |
|
60 * @return expiry in seconds |
|
61 */ |
|
62 TUint ExpiryApi(); |
|
63 |
|
64 /** |
|
65 * Winfo-expiry accessor |
|
66 * @return expiry in seconds |
|
67 */ |
|
68 TUint ExpiryWinfo(); |
|
69 |
|
70 /** |
|
71 * CLIENT-OBJ-DATA-LIMIT accessor |
|
72 * @return CLIENT-OBJ-DATA-LIMIT |
|
73 */ |
|
74 TInt ObjLimit(); |
|
75 |
|
76 /** |
|
77 * SOURCE-THROTTLE-PUBLISH accessor |
|
78 * @return SOURCE-THROTTLE-PUBLISH |
|
79 */ |
|
80 TInt Throttle(); |
|
81 |
|
82 /** |
|
83 * MAX-NUMBER-OF-PRESENCE-SUBSCRIPTIONS accessor |
|
84 * @return MAX-NUMBER-OF-PRESENCE-SUBSCRIPTIONS |
|
85 */ |
|
86 TInt MaxSubscriptions(); |
|
87 |
|
88 /** |
|
89 * SIP Profile Id |
|
90 * @return SIP Profile Id, 0 means default |
|
91 */ |
|
92 TInt SipProfileId(); |
|
93 |
|
94 /** |
|
95 * Read static settings from central repository |
|
96 */ |
|
97 void ReadCentRepSettings( ); |
|
98 |
|
99 /** |
|
100 * Read OTA settings from central repository |
|
101 * @param aSetId SIMPLE settings id |
|
102 */ |
|
103 void ReadOTASettingsL( TInt aSetId ); |
|
104 |
|
105 |
|
106 #ifdef _DEBUG |
|
107 /** |
|
108 * Read optional ini file |
|
109 * @param aFs file system handle |
|
110 * @leave if file not found |
|
111 */ |
|
112 void ReadIniFileL( RFs& aFs ); |
|
113 #endif |
|
114 |
|
115 private: |
|
116 |
|
117 /** |
|
118 * Get integer value from Central Repository. |
|
119 * @param aRepository repository |
|
120 * @param aId key id |
|
121 * @return value of the key |
|
122 */ |
|
123 TInt TSimpleSettings::GetCenRepIntValueL( |
|
124 CRepository* aRepository, |
|
125 TUint32 aId ); |
|
126 |
|
127 private: //data |
|
128 |
|
129 /** |
|
130 * Publish expiry time |
|
131 */ |
|
132 TUint iExpiryPuhlish; |
|
133 |
|
134 /** |
|
135 * Watcher expiry time |
|
136 */ |
|
137 TUint iExpiryWatcher; |
|
138 |
|
139 /** |
|
140 * Winfo watcher expiry time |
|
141 */ |
|
142 TUint iExpiryWinfo; |
|
143 |
|
144 /** |
|
145 * API request expiry time |
|
146 */ |
|
147 TUint iExpiryApi; |
|
148 |
|
149 /** |
|
150 * CLIENT-OBJ-DATA-LIMIT |
|
151 */ |
|
152 TInt iObjLimit; |
|
153 |
|
154 /** |
|
155 * SOURCE-THROTTLE-PUBLISH |
|
156 */ |
|
157 TInt iThrottle; |
|
158 |
|
159 /** |
|
160 * MAX-NUMBER-OF-PRESENCE-SUBSCRIPTIONS |
|
161 */ |
|
162 TInt iMaxSubscriptions; |
|
163 |
|
164 /** |
|
165 * Sip Profile Id |
|
166 */ |
|
167 TInt iSipProfileId; |
|
168 |
|
169 #ifdef _DEBUG |
|
170 friend class T_TSimpleSettings; |
|
171 friend class T_CSimpleSipConnection; |
|
172 #endif |
|
173 }; |
|
174 |
|
175 #endif // simplesettings_H |
|
176 |
|
177 // End of File |