VR-Forces 4.6 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DtNameValueLists.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 2012 MAK Technologies, Inc.
3 ** All rights reserved.
4 ******************************************************************************/
7 
8 #pragma once
9 
13 
14 namespace makArchives
15 {
16 
22  {
23  public:
26 
29 
31  DtNameValueLists& operator=(const DtNameValueLists& rhs);
32 
34  bool operator==(const DtNameValueLists& rhs) const;
35 
37  bool operator!=(const DtNameValueLists& rhs);
38 
40 
41  typedef std::map<std::string, int> ParametersInt;
42  typedef std::map<std::string, bool> ParametersBool;
43  typedef std::map<std::string, double> ParametersDouble;
44  typedef std::map<std::string, std::string> ParametersString;
46 
48 
49  int parameterInt( const std::string& parameterName ) const;
50  double parameterDouble( const std::string& parameterName ) const;
51  bool parameterBool( const std::string& parameterName ) const;
52  const std::string& parameterString( const std::string& parameterName ) const;
54 
56 
57  void setParameterInt( const std::string& parameterName, int value );
58  void setParameterDouble( const std::string& parameterName, double value );
59  void setParameterBool( const std::string& parameterName, bool value );
60  void setParameterString( const std::string& parameterName, const std::string& value );
62 
64 
65  bool hasParameterInt( const std::string& parameterName ) const;
66  bool hasParameterDouble( const std::string& parameterName ) const;
67  bool hasParameterBool( const std::string& parameterName ) const;
68  bool hasParameterString( const std::string& parameterName ) const;
70  bool hasParameter( const std::string& parameterName ) const;
72 
74 
75  const ParametersInt& parametersInt() const;
76  const ParametersDouble& parametersDouble() const;
77  const ParametersBool& parametersBool() const;
78  const ParametersString& parametersString() const;
80 
82 
83  void setParametersInt(const ParametersInt& parameters);
84  void setParametersBool(const ParametersBool& parameters);
85  void setParametersDouble(const ParametersDouble& parameters);
86  void setParametersString(const ParametersString& parameters);
88 
89  protected:
90  friend class boost::serialization::access;
91 
92  template<class Archive>
93  void serialize(Archive & ar, const unsigned int version)
94  {
95  ar & BOOST_SERIALIZATION_NVP(myParametersInt);
96  ar & BOOST_SERIALIZATION_NVP(myParametersBool);
97  ar & BOOST_SERIALIZATION_NVP(myParametersDouble);
98  ar & BOOST_SERIALIZATION_NVP(myParametersString);
99  }
100 
105  };
106 }
108 

Document ID: Generated on Thu Apr 12 03:15:37 EDT 2018 from SVN revision 187986
Copyright © 2005-2018 VT MÄK. All Rights Reserved (www.mak.com)