107#define USE_DEFAULT_STREAMS
123#ifdef USE_DEFAULT_STREAMS
126#define mcout std::cout
128#define mcerr std::cerr
132#define OPEN_LOGFILE_EXPLICITLY
136class HelperForMcout {
141 static std::ofstream& get_ofstream(
void) {
142 static std::ofstream prstream_output_file;
143 return prstream_output_file;
146 HelperForMcout(
void) {
147#ifndef OPEN_LOGFILE_EXPLICITLY
149 get_ofstream().open(
"prstream_log.out");
155 ~HelperForMcout(
void) {
157 get_ofstream().flush();
158 get_ofstream().close();
164HelperForMcout __helper_for_mcout;
169#define mcout HelperForMcout::get_ofstream()
170#define mcerr HelperForMcout::get_ofstream()
183extern indentation
indn;
189 for (
int n = 0; n < ind.
n; n++) file <<
' ';
193std::ostream&
noindent(std::ostream& f);
196#define Ifile file << indn
197#define Imcout mcout << indn
198#define Iprint(file, name) \
199 file << indn << #name << "=" << noindent << name << yesindent;
200#define Iprintf(file, name) \
202 file << indn << #name << "=" << noindent << name << yesindent; \
205#define Iprintn(file, name) \
206 file << indn << #name << "=" << noindent << name << '\n' << yesindent;
207#define Iprintnf(file, name) \
209 file << indn << #name << "=" << noindent << name << '\n' << yesindent; \
212#define Iprintan(file, name, addition) \
213 file << indn << #name << "=" << noindent << name << ' ' << addition << '\n' \
217#define Iprint2(file, name1, name2) \
218 file << indn << #name1 << "=" << noindent << name1 << ", " << #name2 << "=" \
219 << noindent << name2 << yesindent;
220#define Iprint2n(file, name1, name2) \
221 file << indn << #name1 << "=" << noindent << name1 << ", " << #name2 << "=" \
222 << noindent << name2 << '\n' << yesindent;
223#define Iprint2nf(file, name1, name2) \
225 file << indn << #name1 << "=" << noindent << name1 << ", " << #name2 \
226 << "=" << noindent << name2 << '\n' << yesindent; \
229#define Iprint3(file, name1, name2, name3) \
230 file << indn << #name1 << "=" << noindent << name1 << ", " << #name2 << "=" \
231 << noindent << name2 << ", " << #name3 << "=" << noindent << name3 \
233#define Iprint3n(file, name1, name2, name3) \
234 file << indn << #name1 << "=" << noindent << name1 << ", " << #name2 << "=" \
235 << noindent << name2 << ", " << #name3 << "=" << noindent << name3 \
236 << '\n' << yesindent;
237#define Iprint3nf(file, name1, name2, name3) \
239 file << indn << #name1 << "=" << noindent << name1 << ", " << #name2 \
240 << "=" << noindent << name2 << ", " << #name3 << "=" << noindent \
241 << name3 << '\n' << yesindent; \
244#define Iprint4n(file, name1, name2, name3, name4) \
245 file << indn << #name1 << "=" << noindent << name1 << ", " << #name2 << "=" \
246 << noindent << name2 << ", " << #name3 << "=" << noindent << name3 \
247 << ", " << #name4 << "=" << noindent << name4 << '\n' << yesindent;
std::ostream & noindent(std::ostream &f)
std::ostream & operator<<(std::ostream &file, const BGMesh &bgm)
std::ostream & yesindent(std::ostream &f)