General Purpose Geodetic Library
VcSetup.h
Go to the documentation of this file.
1 /*
2  * This file is a part of vgosDbCalc. vgosDbCalc is a part of CALC/SOLVE
3  * system and is designed to calculate theoretical values and store them
4  * in the vgosDb format.
5  * Copyright (C) 2016-2020 Sergei Bolotin.
6  *
7  * This program is free software: you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation, either version 3 of the License, or
10  * (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program. If not, see <http://www.gnu.org/licenses/>.
19  *
20  */
21 
22 #ifndef VC_SETUP_H
23 #define VC_SETUP_H
24 
25 
26 #ifdef HAVE_CONFIG_H
27 # include <config.h>
28 #endif
29 
30 
31 #include <QtCore/QString>
32 
33 
34 #include <SgIdentities.h>
35 
36 
37 /***===================================================================================================*/
43 class VcSetup
44 {
45 public:
46  //
47  // constructors/destructors:
48  //
51  VcSetup();
52 
56  virtual ~VcSetup();
57 
58 
59 
60  //
61  // Interfaces:
62  //
63  // gets:
66  inline const QString& getPath2Home() const;
67 
70  inline const QString& getPath2VgosDbFiles() const;
71 
74  inline const QString& getPath2SolveAprioriFiles() const;
75 
78  inline const QString& getPath2MasterFiles() const;
79 
80  inline const QString& getAprioriFile4Sites() const {return aPrioriFile4Sites_;};
81  inline const QString& getAprioriFile4Sources() const {return aPrioriFile4Sources_;};
82  inline const QString& getAprioriFile4OceanLd() const {return aPrioriFile4OceanLd_;};
83  inline const QString& getAprioriFile4Eops() const {return aPrioriFile4Eops_;};
84  inline const QString& getAprioriFile4Tilts() const {return aPrioriFile4Tilts_;};
85  inline const QString& getAprioriFile4OceanPoleTideLd() const {return aPrioriFile4OceanPoleTideLd_;};
86 
89  inline const QString& getPath2AuxLogs() const;
90 
93  inline bool getHave2SavePerSessionLog() const;
94 
97  inline bool getUseLocalLocale() const {return useLocalLocale_;};
98 
101  inline const SgIdentities& getIdentities() const;
102 
105  inline SgIdentities& identities();
106 
107 
108 
109  //
110  // sets:
113  inline void setPath2Home(const QString&);
114 
117  inline void setPath2VgosDbFiles(const QString&);
118 
121  inline void setPath2SolveAprioriFiles(const QString&);
122 
125  inline void setPath2MasterFiles(const QString&);
126 
127  inline void setAprioriFile4Sites(const QString& file) {aPrioriFile4Sites_ = file;};
128  inline void setAprioriFile4Sources(const QString& file) {aPrioriFile4Sources_ = file;};
129  inline void setAprioriFile4OceanLd(const QString& file) {aPrioriFile4OceanLd_ = file;};
130  inline void setAprioriFile4Eops(const QString& file) {aPrioriFile4Eops_ = file;};
131  inline void setAprioriFile4Tilts(const QString& file) {aPrioriFile4Tilts_ = file;};
132  inline void setAprioriFile4OceanPoleTideLd(const QString& file) {aPrioriFile4OceanPoleTideLd_ = file;};
133 
136  inline void setPath2AuxLogs(const QString&);
137 
138  inline void setUseLocalLocale(bool use) {useLocalLocale_ = use;};
139 
142  inline void setHave2SavePerSessionLog(bool);
143 
146  inline void setIdentities(const SgIdentities&);
147 
148 
149  //
150  // Functions:
151  //
152  inline QString className() const {return "VpSetup";};
153 
154  void setUpBinaryIdentities(const QString&);
155 
156  inline QString path2(const QString&) const;
157 
158  void print2stdOut();
159 
160  //
161  // Friends:
162  //
163 
164 
165 
166  //
167  // I/O:
168  //
169  //
170 
171 
172 private:
173  // pathes:
174  QString path2Home_;
184  QString path2AuxLogs_;
187  // identities:
189 };
190 /*=====================================================================================================*/
191 
192 
193 
194 
195 
196 /*=====================================================================================================*/
197 /* */
198 /* VpSetup inline members: */
199 /* */
200 /*=====================================================================================================*/
201 //
202 //
203 //
204 // INTERFACES:
205 //
206 //
207 inline const QString& VcSetup::getPath2Home() const
208 {
209  return path2Home_;
210 };
211 
212 
213 
214 //
215 inline const QString& VcSetup::getPath2VgosDbFiles() const
216 {
217  return path2VgosDbFiles_;
218 };
219 
220 
221 
222 //
223 inline const QString& VcSetup::getPath2SolveAprioriFiles() const
224 {
226 };
227 
228 
229 
230 //
231 inline const QString& VcSetup::getPath2MasterFiles() const
232 {
233  return path2MasterFiles_;
234 };
235 
236 
237 
238 //
239 inline const QString& VcSetup::getPath2AuxLogs() const
240 {
241  return path2AuxLogs_;
242 };
243 
244 
245 
246 //
248 {
250 };
251 
252 
253 
254 //
256 {
257  return identities_;
258 };
259 
260 
261 
262 //
264 {
265  return identities_;
266 };
267 
268 
269 
270 //
271 // sets:
272 //
273 inline void VcSetup::setPath2Home(const QString& str)
274 {
275  path2Home_ = str;
276 };
277 
278 
279 
280 //
281 inline void VcSetup::setPath2VgosDbFiles(const QString& str)
282 {
283  path2VgosDbFiles_ = str;
284 };
285 
286 
287 
288 //
289 inline void VcSetup::setPath2SolveAprioriFiles(const QString& str)
290 {
292 };
293 
294 
295 
296 //
297 inline void VcSetup::setPath2MasterFiles(const QString& str)
298 {
299  path2MasterFiles_ = str;
300 };
301 
302 
303 
304 //
305 inline void VcSetup::setPath2AuxLogs(const QString& str)
306 {
307  path2AuxLogs_ = str;
308 };
309 
310 
311 
312 //
313 inline void VcSetup::setHave2SavePerSessionLog(bool have2)
314 {
315  have2SavePerSessionLog_ = have2;
316 };
317 
318 
319 
320 //
321 inline void VcSetup::setIdentities(const SgIdentities& id)
322 {
323  identities_ = id;
324 };
325 
326 
327 
328 //
329 inline QString VcSetup::path2(const QString& path) const
330 {
331  return
332  path.size()==0 ? path2Home_ :
333  (path.at(0)==QChar('/') ? path : path2Home_ + "/" + path);
334 };
335 /*=====================================================================================================*/
336 #endif // VC_SETUP_H
bool have2SavePerSessionLog_
Definition: VcSetup.h:185
void setPath2SolveAprioriFiles(const QString &)
Definition: VcSetup.h:289
void setIdentities(const SgIdentities &)
Definition: VcSetup.h:321
QString path2MasterFiles_
Definition: VcSetup.h:176
const QString & getAprioriFile4Sources() const
Definition: VcSetup.h:81
const QString & getAprioriFile4Sites() const
Definition: VcSetup.h:80
const QString & getAprioriFile4Tilts() const
Definition: VcSetup.h:84
QString aPrioriFile4Eops_
Definition: VcSetup.h:181
void setAprioriFile4Tilts(const QString &file)
Definition: VcSetup.h:131
bool getHave2SavePerSessionLog() const
Definition: VcSetup.h:247
QString aPrioriFile4Sites_
Definition: VcSetup.h:178
QString aPrioriFile4Sources_
Definition: VcSetup.h:179
const QString & getPath2Home() const
Definition: VcSetup.h:207
const QString & getPath2SolveAprioriFiles() const
Definition: VcSetup.h:223
QString path2Home_
Definition: VcSetup.h:174
void setAprioriFile4OceanPoleTideLd(const QString &file)
Definition: VcSetup.h:132
const SgIdentities & getIdentities() const
Definition: VcSetup.h:255
void setAprioriFile4Sites(const QString &file)
Definition: VcSetup.h:127
void setPath2MasterFiles(const QString &)
Definition: VcSetup.h:297
QString path2(const QString &) const
Definition: VcSetup.h:329
const QString & getAprioriFile4OceanLd() const
Definition: VcSetup.h:82
VcSetup()
Definition: VcSetup.cpp:45
bool useLocalLocale_
Definition: VcSetup.h:186
void setPath2AuxLogs(const QString &)
Definition: VcSetup.h:305
const QString & getPath2VgosDbFiles() const
Definition: VcSetup.h:215
const QString & getPath2MasterFiles() const
Definition: VcSetup.h:231
bool getUseLocalLocale() const
Definition: VcSetup.h:97
void setAprioriFile4Eops(const QString &file)
Definition: VcSetup.h:130
SgIdentities identities_
Definition: VcSetup.h:188
void setPath2VgosDbFiles(const QString &)
Definition: VcSetup.h:281
void setUseLocalLocale(bool use)
Definition: VcSetup.h:138
QString aPrioriFile4Tilts_
Definition: VcSetup.h:182
QString aPrioriFile4OceanPoleTideLd_
Definition: VcSetup.h:183
const QString & getAprioriFile4Eops() const
Definition: VcSetup.h:83
QString aPrioriFile4OceanLd_
Definition: VcSetup.h:180
const QString & getPath2AuxLogs() const
Definition: VcSetup.h:239
SgIdentities & identities()
Definition: VcSetup.h:263
const QString & getAprioriFile4OceanPoleTideLd() const
Definition: VcSetup.h:85
void setHave2SavePerSessionLog(bool)
Definition: VcSetup.h:313
void setAprioriFile4Sources(const QString &file)
Definition: VcSetup.h:128
void setPath2Home(const QString &)
Definition: VcSetup.h:273
void setUpBinaryIdentities(const QString &)
Definition: VcSetup.cpp:74
QString path2VgosDbFiles_
Definition: VcSetup.h:175
void setAprioriFile4OceanLd(const QString &file)
Definition: VcSetup.h:129
QString className() const
Definition: VcSetup.h:152
QString path2AuxLogs_
Definition: VcSetup.h:184
virtual ~VcSetup()
Definition: VcSetup.cpp:67
QString path2SolveAprioriFiles_
Definition: VcSetup.h:177
void print2stdOut()
Definition: VcSetup.cpp:86