Go to the documentation of this file.
77 void align(ofstream& ofs,
bool& is_first_parameter,
const String& indent)
80 if (is_first_parameter)
81 is_first_parameter =
false;
116 cout <<
"The file wsv.h is not up to date!\n";
117 cout <<
"(N_WSV = " <<
N_WSV <<
", n_wsv = " << n_wsv <<
")\n";
118 cout <<
"Make wsv.h first. Check if Makefile is correct.\n";
127 ofs <<
"// This file was generated automatically by make_auto_md_h.cc.\n";
128 ofs <<
"// DO NOT EDIT !\n";
129 ofs <<
"// Generated: "
131 << __TIME__ <<
"\n\n";
133 ofs <<
"#ifndef auto_md_h\n";
134 ofs <<
"#define auto_md_h\n\n";
136 ofs <<
"#include \"matpackI.h\"\n"
137 <<
"#include \"los.h\"\n"
138 <<
"#include \"absorption.h\"\n"
139 <<
"#include \"auto_wsv.h\"\n"
140 <<
"#include \"parser.h\"\n"
143 ofs <<
"// This is only used for a consistency check. You can get the\n"
144 <<
"// number of workspace variables from wsv_data.nelem().\n"
145 <<
"#define N_MD " << n_md <<
"\n\n";
147 ofs <<
"enum MdHandle{\n";
148 for (
Index i=0; i<n_md-1; ++i)
150 ofs <<
" " <<
md_data[i].Name() <<
"_,\n";
152 ofs <<
" " <<
md_data[n_md-1].Name() <<
"_\n";
156 ofs <<
"// Method function declarations:\n\n";
157 for (
Index i=0; i<n_md; ++i)
162 bool is_first_parameter =
true;
180 for (ArrayOfIndex::const_iterator j=vo.begin(); j<vo.end(); ++j)
181 for (ArrayOfIndex::iterator k=vi.begin(); k<vi.end(); ++k)
202 ofs <<
"void " <<
md_data[i].Name() <<
"(";
207 bool is_first_of_these =
true;
212 align(ofs,is_first_parameter,indent);
215 if (is_first_of_these)
217 ofs <<
"// WS Output:\n";
219 is_first_of_these =
false;
229 bool is_first_of_these =
true;
234 align(ofs,is_first_parameter,indent);
237 if (is_first_of_these)
239 ofs <<
"// WS Generic Output:\n";
241 is_first_of_these =
false;
251 bool is_first_of_these =
true;
256 align(ofs,is_first_parameter,indent);
259 if (is_first_of_these)
261 ofs <<
"// WS Generic Output Names:\n";
263 is_first_of_these =
false;
266 ofs <<
"const String&";
273 bool is_first_of_these =
true;
278 align(ofs,is_first_parameter,indent);
281 if (is_first_of_these)
283 ofs <<
"// WS Input:\n";
285 is_first_of_these =
false;
296 bool is_first_of_these =
true;
301 align(ofs,is_first_parameter,indent);
304 if (is_first_of_these)
306 ofs <<
"// WS Generic Input:\n";
308 is_first_of_these =
false;
319 bool is_first_of_these =
true;
324 align(ofs,is_first_parameter,indent);
327 if (is_first_of_these)
329 ofs <<
"// WS Generic Input Names:\n";
331 is_first_of_these =
false;
334 ofs <<
"const String&";
341 bool is_first_of_these =
true;
346 for (
Index j=0; j!=n_mr; ++j)
349 align(ofs,is_first_parameter,indent);
352 if (is_first_of_these)
354 ofs <<
"// Control Parameters:\n";
356 is_first_of_these =
false;
369 ofs <<
"// Get-away function declarations:\n\n";
370 for (
Index i=0; i<n_md; ++i)
371 ofs <<
"void " <<
md_data[i].Name()
372 <<
"_g(WorkSpace& ws, const MRecord& mr);\n";
376 ofs <<
"\n#endif // auto_md_h\n";
384 cout <<
"Something went wrong. Message text:\n";
385 cout << x.what() <<
'\n';
void define_wsv_data()
Define the lookup data for the workspace variables.
const Array< WsvRecord > wsv_data
This file contains the definition of Array.
This can be used to make arrays out of anything.
void define_md_data()
Define the lookup data for the workspace methods.
void align(ofstream &ofs, bool &is_first_parameter, const String &indent)
ArrayOfString wsv_group_names
void define_wsv_group_names()
Define the array of workspace variable group names.
void open_output_file(ofstream &file, const String &name)
Open a file for writing.
Array< MdRecord > md_data
The lookup information for the workspace methods.
INDEX Index
The type to use for all integer numbers and indices.
String TokValTypeName[7]
The name of the type associated with the different tokens.
This file contains basic functions to handle ASCII and binary (HDF) data files.
Index nelem() const
Number of elements.
Declaration of the class MdRecord.
Auxiliary header stuff related to workspace variable groups.
Declares the enum type that acts as a handle for workspace variables. Also declares the workspace its...
The global header file for ARTS.