|
1 /** |
|
2 * Copyright (c) 2008-2009 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 * Usb Battery Charging test code to write to the Repository |
|
16 * |
|
17 * |
|
18 */ |
|
19 |
|
20 |
|
21 |
|
22 #include <e32base.h> |
|
23 #include "activepropertysubscribercharging.h" |
|
24 |
|
25 class CRepository; |
|
26 class CActivePropertySubscriber; |
|
27 |
|
28 |
|
29 NONSHARABLE_CLASS(CPropertyBatteryCharging) : public CBase |
|
30 ,public MPropertyWriteRepositoryObserver |
|
31 ,public MPropertyReadBatteryChargingCurrentObserver |
|
32 { |
|
33 public: |
|
34 static CPropertyBatteryCharging* NewL(); |
|
35 ~CPropertyBatteryCharging(); |
|
36 |
|
37 private: |
|
38 CPropertyBatteryCharging(); |
|
39 void ConstructL(); |
|
40 void DefinePropertiesL(); |
|
41 |
|
42 void DefinePropertyL(const TInt32 aCategory, TUint aKey,RProperty::TType eType); |
|
43 |
|
44 private: |
|
45 // from MPropertyWriteRepositoryObserver |
|
46 void MpsoPropertyWriteChanged(const TInt aValue); |
|
47 |
|
48 // from MPropertyReadBatteryChargingCurrentObserver |
|
49 void MpsoPropertyReadChanged(); |
|
50 |
|
51 |
|
52 |
|
53 |
|
54 private: // owned |
|
55 CActivePropertyWriteRepository* iActiveWriteRepository; |
|
56 CActivePropertyReadChargingCurrent* iActiveReadChargingCurrent; |
|
57 CRepository* iRepository; |
|
58 |
|
59 //RProperty iPropertyWrittenToRepositoryAck; |
|
60 //RProperty iPropertyReadChargingCurrentAck; |
|
61 RProperty iProperty; // only one protected needed ? |
|
62 |
|
63 |
|
64 }; |