380 std::getline(fis, theline);
382 std::string lineID=theline.substr(0,4);
383 if (!helper::IDmatch<SRCE>(lineID))
throw 384 GSE2::Terror(
"ERROR (SRCE::read): missing SRCE ID!");
386 this->
type=theline.substr(5,20);
388 { std::cerr <<
"DEBUG (SRCE::read): type: " <<
type << std::endl; }
390 this->
cs=
coosysID(*theline.substr(26,1).c_str());
391 this->
cx=atof(theline.substr(28,15).c_str());
392 this->
cy=atof(theline.substr(43,15).c_str());
393 this->
cz=atof(theline.substr(58,15).c_str());
396 std::cerr <<
"DEBUG (SRCE::read): cs,cx,cy,cz: " 400 std::string datestring,timestring;
401 datestring=theline.substr(74,6);
402 timestring=theline.substr(81,10);
405 std::cerr <<
"DEBUG (SRCE::read): datestring: " 406 << datestring << std::endl;
407 std::cerr <<
"DEBUG (SRCE::read): timestring: " 408 << timestring << std::endl;
410 std::string fulldate(
"");
411 fulldate+=datestring.substr(0,2);
413 fulldate+=datestring.substr(2,2);
415 fulldate+=datestring.substr(4,2);
417 fulldate+=timestring.substr(0,2);
419 fulldate+=timestring.substr(2,2);
421 fulldate+=timestring.substr(4,6);
424 std::cerr <<
"DEBUG (SRCE::read): convert string: " 425 << fulldate << std::endl;
427 this->
date=libtime::TAbsoluteTime(fulldate);
430 std::cerr <<
"DEBUG (SRCE::read): time: " 431 <<
date.timestring() << std::endl;
char coosysID(const Ecoosys &csid)
libtime::TAbsoluteTime date
time of source