|
0
|
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 |
|
|
|
19 |
#ifndef __ANALYSERPARAMS_H__
|
|
|
20 |
#define __ANALYSERPARAMS_H__
|
|
|
21 |
|
|
|
22 |
#ifdef __WIN__
|
|
|
23 |
#pragma warning(disable:4786)
|
|
|
24 |
#endif
|
|
|
25 |
|
|
|
26 |
#include <string>
|
|
|
27 |
#include <map>
|
|
|
28 |
|
|
|
29 |
using namespace std;
|
|
|
30 |
|
|
|
31 |
/**
|
|
|
32 |
* AnalyserParams is used as a container for parameters given from commandline
|
|
|
33 |
* and internal parameters.
|
|
|
34 |
*/
|
|
|
35 |
class AnalyserParams
|
|
|
36 |
{
|
|
|
37 |
public:
|
|
|
38 |
/**
|
|
|
39 |
* Check if the parameter exist
|
|
|
40 |
* @param aParm param to check
|
|
|
41 |
* @return true/false
|
|
|
42 |
*/
|
|
|
43 |
bool parameterExists(const string& aParm);
|
|
|
44 |
|
|
|
45 |
/**
|
|
|
46 |
* Check if the parameter is given
|
|
|
47 |
* @param aParm param to check
|
|
|
48 |
* @return true if the parameter is given
|
|
|
49 |
*/
|
|
|
50 |
bool givenParameter(const string& aParm);
|
|
|
51 |
|
|
|
52 |
/**
|
|
|
53 |
* Store the parameter
|
|
|
54 |
* @param parm parameter to store
|
|
|
55 |
* @param val parameter value
|
|
|
56 |
* @param aFromCmdline (true if the parameter is read from the commandline)
|
|
|
57 |
*/
|
|
|
58 |
void storeParameter(string parm, string val, bool aFromCmdline = false);
|
|
|
59 |
|
|
|
60 |
/**
|
|
|
61 |
* Get given parameter
|
|
|
62 |
* @param parm given parameter
|
|
|
63 |
* @return value of the give parameter
|
|
|
64 |
*/
|
|
|
65 |
string getParameter(const string& parm);
|
|
|
66 |
|
|
|
67 |
/**
|
|
|
68 |
* Get given parameters from the parameter map
|
|
|
69 |
* @return map of given parameters
|
|
|
70 |
*/
|
|
|
71 |
const map <string, string> getGivenParameters();
|
|
|
72 |
|
|
|
73 |
private:
|
|
|
74 |
//! map of Header analyser parameters
|
|
|
75 |
map<string,pair<string,bool> > iParameters;
|
|
|
76 |
};
|
|
|
77 |
#endif
|