VR-Forces 4.8 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DtStringKeyConverter.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 2010 MAK Technologies, Inc.
3 ** All rights reserved.
4 ******************************************************************************/
5 /******************************************************************************
6 ** $RCSfile: DtStringKeyConverter.h,v $ $Revision: 1.1 $ $State: Exp $
7 ******************************************************************************/
8 
12 
13 #pragma once
14 
15 #include <vrvCore/vrvCore.h>
16 
17 #include <map>
18 #include <string>
19 
20 namespace makVrv
21 {
22  class DtDe;
23 
34  {
35  public:
36 
38  typedef std::map< std::string, int > StringKeyToIntKeyMap;
40  typedef std::map< int, std::string > IntKeyToStringKeyMap;
41 
44 
47 
48  private:
51 
53  DtStringKeyConverter& operator=(const DtStringKeyConverter&);
54 
55  public:
56 
59  int registerStringKey( const std::string& stringKey );
60 
63  void registerStringKey( const std::string& stringKey, int intKey );
64 
67  int lookupIntKey( const std::string& stringKey ) const;
68 
71  const std::string* findStringKey( int intKey ) const;
72 
75  const StringKeyToIntKeyMap& stringKeys() const;
76 
79  const IntKeyToStringKeyMap& intKeys() const;
80 
82  void removeKey( int intKey );
83 
85  void removeKey( const std::string& stringKey );
86 
87  protected:
88 
92  };
93 
94 }
95 
96 
std::map< int, std::string > IntKeyToStringKeyMap
Type of map of integer keys to sting keys.
Definition: DtStringKeyConverter.h:40
std::map< std::string, int > StringKeyToIntKeyMap
Type of map of string keys to integer keys.
Definition: DtStringKeyConverter.h:38
DtStringKeyConverter is used to convert string-based keys, used in files for things like model sets a...
Definition: DtStringKeyConverter.h:33
#define DT_DLL_VRVCORE
Definition: vrvCore.h:20
StringKeyToIntKeyMap myStringKeyToIntKeyMap
Definition: DtStringKeyConverter.h:89
IntKeyToStringKeyMap myIntKeyToStringKeyMap
Definition: DtStringKeyConverter.h:90
int myNextIntKey
Definition: DtStringKeyConverter.h:91
Contains DLL export macros.

Document ID: Generated on Thu Aug 27 10:56:05 EDT 2020 from SVN revision 217100
Copyright © 2005-2020 MAK Technologies. All Rights Reserved (www.mak.com)