|
1 // Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies). |
|
2 // All rights reserved. |
|
3 // This component and the accompanying materials are made available |
|
4 // under the terms of "Eclipse Public License v1.0" |
|
5 // which accompanies this distribution, and is available |
|
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
7 // |
|
8 // Initial Contributors: |
|
9 // Nokia Corporation - initial contribution. |
|
10 // |
|
11 // Contributors: |
|
12 // |
|
13 // Description: |
|
14 // $Header$ |
|
15 // GT0149 Applications Protocol Integration Test Harness |
|
16 // blank application |
|
17 // This header file defines the abstract base class CCmdPar. |
|
18 // It is used for deriving different SET commands. |
|
19 // |
|
20 // |
|
21 |
|
22 #ifndef __CCMDPAR_H__ |
|
23 #define __CCMDPAR_H__ |
|
24 |
|
25 //----------------------------------------------------------------------------- |
|
26 // Include Files |
|
27 |
|
28 #include <e32base.h> |
|
29 #include <e32cons.h> |
|
30 |
|
31 //----------------------------------------------------------------------------- |
|
32 |
|
33 //#include "TextCommands.h" |
|
34 #include "TfrLex.h" |
|
35 #include "TEngine.h" |
|
36 #include "CCmdBase.h" |
|
37 #include "CCmdFamily.h" |
|
38 |
|
39 //---------------------------------------------------------------------------- |
|
40 |
|
41 class CCmdPar : public CCmdBase |
|
42 { |
|
43 public: // Construction and destruction |
|
44 |
|
45 // No allocation because used only as a base type |
|
46 virtual ~CCmdPar(); |
|
47 |
|
48 protected: // From CCmdBase |
|
49 |
|
50 void ConstructL( TInt aCommandId, const TDesC& aKeyphrase); |
|
51 CCmdPar() {}; |
|
52 |
|
53 public: // From CCmdBase |
|
54 |
|
55 TInt ProcessL( const TDesC& aCommand ); |
|
56 |
|
57 public: // New functions |
|
58 |
|
59 // Check and set the value given in this command |
|
60 virtual TInt SetValue(const TDesC& aValue) = 0; |
|
61 |
|
62 // Check and add the value given in this command |
|
63 // (by default gives an error message) |
|
64 virtual TInt AddValue(const TDesC& aValue); |
|
65 |
|
66 // Set the value by reading from a given file |
|
67 // (by default gives an error message) |
|
68 virtual TInt SetFrom(const TDesC& aValue); // +TVi |
|
69 |
|
70 // Return ETrue if the value has been set (or added) |
|
71 // or marks that information as false |
|
72 TBool HasBeenSet(); |
|
73 void MarkNotSet(); |
|
74 |
|
75 private: // Data |
|
76 |
|
77 // Has the value been set |
|
78 TBool iHasBeenSet; |
|
79 }; |
|
80 |
|
81 //---------------------------------------------------------------------------- |
|
82 |
|
83 #endif // __CCMDPAR_H__ |
|
84 |
|
85 //---------------------------------------------------------------------------- |
|
86 // End of File |
|
87 //---------------------------------------------------------------------------- |