Loading...
Searching...
No Matches
gamsparameter.h
1/*
2 * GAMS - General Algebraic Modeling System C++ API
3 *
4 * Copyright (c) 2017-2024 GAMS Software GmbH <support@gams.com>
5 * Copyright (c) 2017-2024 GAMS Development Corp. <support@gams.com>s
6 *
7 * Permission is hereby granted, free of charge, to any person obtaining a copy
8 * of this software and associated documentation files (the "Software"), to deal
9 * in the Software without restriction, including without limitation the rights
10 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
11 * copies of the Software, and to permit persons to whom the Software is
12 * furnished to do so, subject to the following conditions:
13 *
14 * The above copyright notice and this permission notice shall be included in all
15 * copies or substantial portions of the Software.
16 *
17 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
18 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
19 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
20 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
21 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
22 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
23 * SOFTWARE.
24 */
25
26#ifndef GAMSPARAMETER_H
27#define GAMSPARAMETER_H
28
29#include "gamssymbol.h"
30#include "gamsparameterrecord.h"
31
32namespace gams {
33
36class LIBSPEC GAMSParameter : public GAMSSymbol
37{
38public:
40
43
47
50
54
58
63
67 GAMSParameterRecord firstRecord(const std::vector<std::string>& slice);
68
72
76 GAMSParameterRecord firstRecord(const std::string& key1);
77
82 GAMSParameterRecord firstRecord(const std::string& key1, const std::string& key2);
83
89 GAMSParameterRecord firstRecord(const std::string& key1, const std::string& key2, const std::string& key3);
90
94 GAMSParameterRecord lastRecord(const std::vector<std::string>& slice);
95
99
103 GAMSParameterRecord lastRecord(const std::string& key1);
104
109 GAMSParameterRecord lastRecord(const std::string& key1, const std::string& key2);
110
116 GAMSParameterRecord lastRecord(const std::string& key1, const std::string& key2, const std::string& key3);
117
121 GAMSParameterRecord findRecord(const std::vector<std::string>& keys);
122
126
130 GAMSParameterRecord findRecord(const std::string& key1);
131
136 GAMSParameterRecord findRecord(const std::string& key1, const std::string& key2);
137
143 GAMSParameterRecord findRecord(const std::string& key1, const std::string& key2, const std::string& key3);
144
148 GAMSParameterRecord mergeRecord(const std::vector<std::string>& keys);
149
153
157 GAMSParameterRecord mergeRecord(const std::string& key1);
158
163 GAMSParameterRecord mergeRecord(const std::string& key1, const std::string& key2);
164
170 GAMSParameterRecord mergeRecord(const std::string& key1, const std::string& key2, const std::string& key3);
171
175 GAMSParameterRecord addRecord(const std::vector<std::string>& keys);
176
180
184 GAMSParameterRecord addRecord(const std::string& key1);
185
190 GAMSParameterRecord addRecord(const std::string& key1, const std::string& key2);
191
197 GAMSParameterRecord addRecord(const std::string& key1, const std::string& key2, const std::string& key3);
198
199private:
200 friend class GAMSDatabaseImpl;
201 friend class GAMSSymbolIter<GAMSParameter>;
202 GAMSParameter(GAMSDatabase& database, void *symPtr, int dim, std::string name, std::string text);
203 GAMSParameter(GAMSDatabase& database, const std::string& name, const int dim, const std::string& text);
204 GAMSParameter(GAMSDatabase& database, const std::string& name, const std::string& text, const std::vector<GAMSDomain>& domains);
205
206};
207
208
209} // namespace gams
210
211#endif // GAMSPARAMETER_H
This is the representation of a single record of a GAMSParameter.
GAMSParameterRecord lastRecord()
GAMSParameterRecord lastRecord(const std::string &key1, const std::string &key2)
GAMSParameterRecord addRecord(const std::string &key1)
GAMSParameterRecord findRecord(const std::vector< std::string > &keys)
GAMSParameterRecord lastRecord(const std::string &key1, const std::string &key2, const std::string &key3)
GAMSParameterRecord mergeRecord(const std::string &key1, const std::string &key2)
GAMSParameterRecord firstRecord(const std::string &key1, const std::string &key2, const std::string &key3)
GAMSParameterRecord mergeRecord(const std::string &key1, const std::string &key2, const std::string &key3)
GAMSParameterRecord firstRecord(const std::vector< std::string > &slice)
GAMSParameterRecord findRecord(const std::string &key1)
GAMSParameterRecord addRecord(const std::vector< std::string > &keys)
GAMSParameterRecord addRecord()
~GAMSParameter()
Destructor.
GAMSParameterRecord mergeRecord(const std::string &key1)
GAMSSymbolIter< GAMSParameter > begin()
GAMSParameter(const GAMSSymbol &other)
GAMSParameterRecord findRecord(const std::string &key1, const std::string &key2, const std::string &key3)
GAMSSymbolIter< GAMSParameter > end()
GAMSParameterRecord firstRecord()
GAMSParameterRecord firstRecord(const std::string &key1, const std::string &key2)
GAMSParameterRecord firstRecord(const std::string &key1)
GAMSParameterRecord mergeRecord()
GAMSParameterRecord lastRecord(const std::vector< std::string > &slice)
GAMSParameterRecord findRecord(const std::string &key1, const std::string &key2)
GAMSParameterRecord mergeRecord(const std::vector< std::string > &keys)
GAMSParameterRecord lastRecord(const std::string &key1)
GAMSParameter()
Standard constructor.
Definition: gamsparameter.h:42
GAMSParameter & operator=(const GAMSParameter &other)
GAMSParameterRecord addRecord(const std::string &key1, const std::string &key2, const std::string &key3)
GAMSParameterRecord addRecord(const std::string &key1, const std::string &key2)
GAMSParameterRecord findRecord()
Definition: gams.h:91