Teuchos Package Browser (Single Doxygen Collection)  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Teuchos_ValidatorMaps.hpp
Go to the documentation of this file.
1 // @HEADER
2 // *****************************************************************************
3 // Teuchos: Common Tools Package
4 //
5 // Copyright 2004 NTESS and the Teuchos contributors.
6 // SPDX-License-Identifier: BSD-3-Clause
7 // *****************************************************************************
8 // @HEADER
9 
10 #ifndef Teuchos_VALIDATORMAPS_HPP
11 #define Teuchos_VALIDATORMAPS_HPP
12 
18 
19 
20 namespace Teuchos {
21 
22 
25 public:
26 
28  typedef std::map<ParameterEntryValidator::ValidatorID,
30 
32  typedef std::pair<ParameterEntryValidator::ValidatorID,
34 
36  typedef ValidatorMap::iterator iterator;
37 
39  typedef ValidatorMap::const_iterator const_iterator;
40 
42  void insert(IDValidatorPair toInsert);
43 
49  const_iterator find(int id) const;
50 
52  const_iterator begin() const;
53 
55  const_iterator end() const;
56 
58  inline
60  return validatorMap.erase(x);
61  }
62 
63 private:
64 
66 
67 };
68 
69 
72 public:
73 
75  typedef std::map<RCP<const ParameterEntryValidator>, int, RCPComp>
77 
79  typedef std::pair<RCP<const ParameterEntryValidator>, int> ValidatorIDPair;
80 
82  typedef ValidatorMap::iterator iterator;
83 
85  typedef ValidatorMap::const_iterator const_iterator;
86 
89 
91  void insert(RCP<const ParameterEntryValidator> toInsert);
92 
98  const_iterator find(
99  const RCP<const ParameterEntryValidator> validator) const;
100 
102  const_iterator begin() const;
103 
105  const_iterator end() const;
106 
107 private:
108 
110 
111  int counter;
112 
113 };
114 
115 
116 } // namespace Teuchos
117 
118 
119 #endif //Teuchos_VALIDATORMAPS_HPP
std::map< RCP< const ParameterEntryValidator >, int, RCPComp > ValidatorMap
Maps Validators to integers.
size_t erase(const ParameterEntryValidator::ValidatorID &x)
removes the specified validator from the map.
ValidatorMap::const_iterator const_iterator
ValidatorMap::const_iterator const_iterator
Struct for comparing two RCPs. Simply compares the raw pointers contained within the RCPs...
std::pair< RCP< const ParameterEntryValidator >, int > ValidatorIDPair
A class for mapping validators to integers.
#define TEUCHOSPARAMETERLIST_LIB_DLL_EXPORT
std::pair< ParameterEntryValidator::ValidatorID, RCP< ParameterEntryValidator > > IDValidatorPair
Smart reference counting pointer class for automatic garbage collection.
ValidatorMap::iterator iterator
std::map< ParameterEntryValidator::ValidatorID, RCP< ParameterEntryValidator > > ValidatorMap
ValidatorMap::iterator iterator