usbmgmt/usbmgrtest/t_usb_charging/inc/usbchargingarmtest.h
changeset 49 93c0009bd947
equal deleted inserted replaced
48:21625e5de155 49:93c0009bd947
       
     1 /*
       
     2 * Copyright (c) 2006-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 *
       
    16 */
       
    17 
       
    18 #ifndef __USBCHARGINGARM_H__
       
    19 #define __USBCHARGINGARM_H__
       
    20 
       
    21 #include <e32property.h>
       
    22 #include <usbman.h>
       
    23 #include <centralrepository.h>
       
    24 #include <usbchargingpublishedinfo.h>
       
    25 #include <f32file.h>
       
    26 
       
    27 #include "testbase.h"
       
    28 
       
    29 class CUsbChargingCurrentWatcher;
       
    30 class CUsbStateWatcher;
       
    31 /**
       
    32 */
       
    33 class CUsbChargingArmTest : public CTestBase 
       
    34 	{
       
    35 public:
       
    36 	static CTestBase* NewL(MTestManager& aManager);
       
    37 	~CUsbChargingArmTest();
       
    38 	void ShowUsbChargingValue(TPublishedUsbChargingInfo& aValue);
       
    39 	void ShowUsbDeviceState(TUsbDeviceState aDeviceState);
       
    40 	inline RUsb& Usb();
       
    41 
       
    42 private:
       
    43 	CUsbChargingArmTest(MTestManager& aManager);
       
    44 	void ConstructL();
       
    45     void ShowChargingType(TUsbChargingPortType aChargingType);
       
    46     void ShowConnStatus(TUsbConnectionStatus aStatus);
       
    47 	
       
    48 	int StartMassStorage();
       
    49 
       
    50 private: // from CTestBase
       
    51 	void ProcessKeyL(TKeyCode aKeyCode);
       
    52 	void DisplayTestSpecificMenu();
       
    53 
       
    54 private: // owned
       
    55 	RUsb iUsbMan;
       
    56 	CUsbChargingCurrentWatcher* iChargingCurrentWatcher;
       
    57 	CUsbStateWatcher* iUsbStateWatcher;
       
    58 	RFs iFs;
       
    59 	};
       
    60 
       
    61 inline RUsb& CUsbChargingArmTest::Usb()
       
    62     {
       
    63     return iUsbMan;
       
    64     }
       
    65 
       
    66 #endif // __USBCHARGINGARM_H__