5 #include <TApplication.h> 6 #include <TObjectTable.h> 11 #include "MLogManip.h" 16 #include "MParContainer.h" 33 gLog <<
"========================================================" << endl;
34 gLog <<
" Telesto - COSY" << endl;
35 gLog <<
" Telesto - Telescope TPoint organizer" << endl;
36 gLog <<
" Compiled with ROOT v" << ROOT_RELEASE <<
" on <" << __DATE__ <<
">" << endl;
37 gLog <<
"========================================================" << endl;
46 gLog <<
"Sorry the usage is:" << endl;
47 gLog <<
" telestop [file.txt|file.col [pointing.mod]]" << endl << endl;
48 gLog <<
" Arguments:" << endl;
49 gLog <<
" file.txt|file.col A collection of files or a file with tpoints" << endl;
50 gLog <<
" pointing.mod A pointing model to load at startup" << endl << endl;
51 gLog <<
" Root Options:" << endl;
52 gLog <<
" -b Batch mode (no graphical output to screen)" << endl<<endl;
53 gLog <<
" Options:" << endl;
59 gLog <<
" --debug-mem Debug memory usage" << endl << endl;
61 gLog <<
" (Note, that this option can be used multiple times." << endl;
63 gLog <<
" Output options:" << endl;
67 gLog <<
" --version, -V Show startup message with version number" << endl;
68 gLog <<
" -?, -h, --help This help" << endl << endl;
69 gLog <<
"Background:" << endl;
70 gLog <<
" Telesto is a moon of Saturn. It was discovered by Smith, Reitsema," << endl;
71 gLog <<
" Larson and Fountain in 1980 from ground-based observations, and was" << endl;
72 gLog <<
" provisionally designated S/1980 S 13." << endl;
73 gLog <<
" In 1983 it was officially named after Telesto of Greek mythology. It" << endl;
74 gLog <<
" is also designated as Saturn XIII or Tethys B." << endl;
75 gLog <<
" Telesto is co-orbital with Tethys, residing in Tethys' leading" << endl;
76 gLog <<
" Lagrangian point (L4). This relationship was first identified by" << endl;
77 gLog <<
" Seidelmann et al. The moon Calypso also resides in the other" << endl;
78 gLog <<
" (trailing) lagrangian point of Tethys, 60 deg in the other direction." << endl;
79 gLog <<
" The Cassini probe performed a distant flyby of Telesto on Oct. 11," << endl;
80 gLog <<
" 2005. The resulting images show that its surface is surprisingly" << endl;
81 gLog <<
" smooth, devoid of small impact craters." << endl << endl;
84 int main(
int argc,
char **argv)
86 if (!MARS::CheckRootVer())
89 MLog::RedirectErrorHandler(MLog::kColor);
94 MArgs arg(argc, argv);
99 if (arg.HasOnly(
"-V") || arg.HasOnly(
"--version"))
102 if (arg.HasOnly(
"-?") || arg.HasOnly(
"-h") || arg.HasOnly(
"--help"))
108 const Bool_t kDebugMem = arg.HasOnlyAndRemove(
"--debug-mem");
113 if (arg.GetNumArguments()>2)
115 gLog << warn <<
"WARNING - Wrong number of arguments..." << endl;
120 TString fname=arg.GetArgumentStr(0);
121 TString mod =arg.GetArgumentStr(1);
126 if (arg.GetNumOptions()>0)
128 gLog << warn <<
"WARNING - Unknown commandline options..." << endl;
129 arg.Print(
"options");
137 TApplication app(
"telesto", &argc, argv);
138 if (!gClient || gROOT->IsBatch())
140 gLog << err <<
"Bombing... maybe your DISPLAY variable is not set correctly!" << endl;
145 TObject::SetObjectStat(kTRUE);
153 if (TObject::GetObjectStat())
155 TObject::SetObjectStat(kFALSE);
156 gObjectTable->Print();
int main(int argc, char **argv)
static void StartUpMessage()
void SetExitLoopOnClose(Bool_t b=kTRUE)