1 // Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies). |
1 // Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies). |
2 // All rights reserved. |
2 // All rights reserved. |
3 // This component and the accompanying materials are made available |
3 // This component and the accompanying materials are made available |
4 // under the terms of the License "Eclipse Public License v1.0" |
4 // under the terms of the License "Eclipse Public License v1.0" |
5 // which accompanies this distribution, and is available |
5 // which accompanies this distribution, and is available |
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html". |
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html". |
17 // |
17 // |
18 |
18 |
19 #include "modelleddevices.h" |
19 #include "modelleddevices.h" |
20 #include "testinterfacebase.h" |
20 #include "testinterfacebase.h" |
21 #include "testinterfacesettingbase.h" |
21 #include "testinterfacesettingbase.h" |
22 #include "OstTraceDefinitions.h" |
|
23 #ifdef OST_TRACE_COMPILER_IN_USE |
|
24 #include "testdeviceATraces.h" |
|
25 #endif |
|
26 |
|
27 |
|
28 |
22 |
29 |
23 |
30 namespace NUnitTesting_USBDI |
24 namespace NUnitTesting_USBDI |
31 { |
25 { |
32 |
26 |
33 RUsbDeviceA::RUsbDeviceA() |
27 RUsbDeviceA::RUsbDeviceA() |
34 { |
28 { |
35 OstTraceFunctionEntry1( RUSBDEVICEA_RUSBDEVICEA_ENTRY, this ); |
29 LOG_FUNC |
36 OstTraceFunctionExit1( RUSBDEVICEA_RUSBDEVICEA_EXIT, this ); |
|
37 } |
30 } |
38 |
31 |
39 RUsbDeviceA::RUsbDeviceA(CBaseTestCase* aTestCase):RUsbDeviceVendor(aTestCase) |
32 RUsbDeviceA::RUsbDeviceA(CBaseTestCase* aTestCase):RUsbDeviceVendor(aTestCase) |
40 { |
33 { |
41 OstTraceFunctionEntryExt( RUSBDEVICEA_RUSBDEVICEA_ENTRY_DUP01, this ); |
34 LOG_FUNC |
42 OstTraceFunctionExit1( RUSBDEVICEA_RUSBDEVICEA_EXIT_DUP01, this ); |
|
43 } |
35 } |
44 |
36 |
45 RUsbDeviceA::~RUsbDeviceA() |
37 RUsbDeviceA::~RUsbDeviceA() |
46 { |
38 { |
47 OstTraceFunctionEntry1( RUSBDEVICEA_RUSBDEVICEA_ENTRY_DUP02, this ); |
39 LOG_FUNC |
48 OstTraceFunctionExit1( RUSBDEVICEA_RUSBDEVICEA_EXIT_DUP02, this ); |
|
49 } |
40 } |
50 |
41 |
51 |
42 |
52 void RUsbDeviceA::OpenL(const TDesC16& aSerialNumber) |
43 void RUsbDeviceA::OpenL(const TDesC16& aSerialNumber) |
53 { |
44 { |
54 OstTraceFunctionEntryExt( RUSBDEVICEA_OPENL_ENTRY, this ); |
45 LOG_FUNC |
55 |
46 |
56 RUsbDeviceVendor::OpenL(aSerialNumber); |
47 RUsbDeviceVendor::OpenL(aSerialNumber); |
57 |
48 |
58 // Create another interface (interface1) |
49 // Create another interface (interface1) |
59 |
50 |
96 interface1->AddInterfaceSettingL(interface1s1); |
87 interface1->AddInterfaceSettingL(interface1s1); |
97 CleanupStack::Pop(interface1s1); |
88 CleanupStack::Pop(interface1s1); |
98 |
89 |
99 AddInterface(interface1); |
90 AddInterface(interface1); |
100 CleanupStack::Pop(interface1); |
91 CleanupStack::Pop(interface1); |
101 OstTraceFunctionExit1( RUSBDEVICEA_OPENL_EXIT, this ); |
|
102 } |
92 } |
103 |
93 |
104 |
94 |
105 void RUsbDeviceA::OnStateChangeL(TUsbcDeviceState aNewState) |
95 void RUsbDeviceA::OnStateChangeL(TUsbcDeviceState aNewState) |
106 { |
96 { |
107 OstTraceFunctionEntryExt( RUSBDEVICEA_ONSTATECHANGEL_ENTRY, this ); |
97 LOG_FUNC |
108 OstTraceFunctionExit1( RUSBDEVICEA_ONSTATECHANGEL_EXIT, this ); |
|
109 } |
98 } |
110 |
99 |
111 |
100 |
112 } |
101 } |