Open file for writing and pass SRCE line.
c----------------------------------------------------------------------
subroutine sff_WOpenS(lu, filename,
& type, cs, c1, c2, c3, date, time, ierr)
c
c Open file for writing. Write STAT line and SRCE line.
c
c input:
c filename name of file
c type type of source (any 20 character string)
c cs coordinate system (S: spherical, C: cartesian)
c c1, c2, c3 coordiantes as defined by SFF
c time, date time and date of source signal
c output:
c ierr error status (ok: ierr=0)
c
c----------------------------------------------------------------------
78 datrw::oanystream &os=
84 srce.cs=sff::coosysID(*cs);
85 srce.cx=
static_cast<double>(*c1);
86 srce.cy=
static_cast<double>(*c2);
87 srce.cz=
static_cast<double>(*c3);
89 srce.date=
SRCEdate(date, time, date_len, time_len);
datrw::oanystream & open(const int &unit, const std::string &filename)
open a new file
libtime::TAbsoluteTime SRCEdate(char *date, char *time, ftnlen date_len, ftnlen time_len)
create appropriate time string for SRCE line
::fapidxx::OFileUnits ostreammanager
the global ostream manager
std::string stringfromfstring(char *fstring, ftnlen slen)
create a C++ string from a Fortran string