- Timestamp:
- 10/30/11 22:32:48 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Mars/mcore/fits.h
r11964 r12329 22 22 #include <iostream> 23 23 #define gLog cerr 24 #define err""25 #define all""24 #define ___err___ "" 25 #define ___all___ "" 26 26 #else 27 27 #include "MLog.h" 28 28 #include "MLogManip.h" 29 #define ___err___ err 30 #define ___all___ all 29 31 #endif 30 32 … … 108 110 throw runtime_error(str.str()); 109 111 #else 110 gLog << err<< "ERROR - " << str.str() << endl;112 gLog << ___err___ << "ERROR - " << str.str() << endl; 111 113 return false; 112 114 #endif … … 120 122 throw runtime_error(str.str()); 121 123 #else 122 gLog << err<< "ERROR - " << str.str() << endl;124 gLog << ___err___ << "ERROR - " << str.str() << endl; 123 125 return false; 124 126 #endif … … 132 134 throw runtime_error(str.str()); 133 135 #else 134 gLog << err<< "ERROR - " << str.str() << endl;136 gLog << ___err___ << "ERROR - " << str.str() << endl; 135 137 return false; 136 138 #endif … … 261 263 throw runtime_error(str.str()); 262 264 #else 263 gLog << err<< "ERROR - " << str.str() << endl;265 gLog << ___err___ << "ERROR - " << str.str() << endl; 264 266 return; 265 267 #endif … … 278 280 throw runtime_error("Column size mismatch"); 279 281 #else 280 gLog << err<< "ERROR - Column size mismatch" << endl;282 gLog << ___err___ << "ERROR - Column size mismatch" << endl; 281 283 return; 282 284 #endif … … 303 305 continue; 304 306 305 gLog << all<< setw(2) << it->second.type << '|' << it->first << '=' << it->second.value << '/' << it->second.comment << '|' << endl;307 gLog << ___all___ << setw(2) << it->second.type << '|' << it->first << '=' << it->second.value << '/' << it->second.comment << '|' << endl; 306 308 }} 307 309 … … 317 319 for (Sorted::const_iterator it=sorted.begin(); it!=sorted.end(); it++) 318 320 { 319 gLog << all<< setw(6) << it->second.offset << "| ";321 gLog << ___all___ << setw(6) << it->second.offset << "| "; 320 322 gLog << it->second.num << 'x'; 321 323 switch (it->second.type) … … 352 354 throw runtime_error(str.str()); 353 355 #else 354 gLog << err<< "ERROR - " << str.str() << endl;356 gLog << ___err___ << "ERROR - " << str.str() << endl; 355 357 return 0; 356 358 #endif … … 448 450 throw runtime_error("File is not a FITS file."); 449 451 #else 450 gLog << err<< "ERROR - File is not a FITS file." << endl;452 gLog << ___err___ << "ERROR - File is not a FITS file." << endl; 451 453 return; 452 454 #endif … … 468 470 throw runtime_error("FITS file corrupted."); 469 471 #else 470 gLog << err<< "ERROR - FITS file corrupted." << endl;472 gLog << ___err___ << "ERROR - FITS file corrupted." << endl; 471 473 return; 472 474 #endif … … 509 511 seekg((blks+(rest>0?1:0))*(36*80), ios::cur); 510 512 if (!good()) 511 gLog << err<< "File seems to be incomplete (less data than expected from header)." << endl;513 gLog << ___err___ << "File seems to be incomplete (less data than expected from header)." << endl; 512 514 513 515 fRow = fTable.num_rows; … … 591 593 throw runtime_error(str.str()); 592 594 #else 593 gLog << err<< "ERROR - " << str.str() << endl;595 gLog << ___err___ << "ERROR - " << str.str() << endl; 594 596 return false; 595 597 #endif … … 604 606 throw runtime_error(str.str()); 605 607 #else 606 gLog << err<< "ERROR - " << str.str() << endl;608 gLog << ___err___ << "ERROR - " << str.str() << endl; 607 609 return false; 608 610 #endif … … 617 619 throw runtime_error(str.str()); 618 620 #else 619 gLog << err<< "ERROR - " << str.str() << endl;621 gLog << ___err___ << "ERROR - " << str.str() << endl; 620 622 return false; 621 623 #endif … … 664 666 throw runtime_error(str.str()); 665 667 #else 666 gLog << err<< "ERROR - " << str.str() << endl;668 gLog << ___err___ << "ERROR - " << str.str() << endl; 667 669 return false; 668 670 #endif
Note:
See TracChangeset
for help on using the changeset viewer.