DATRW++ library: seismic data I/O with multiple formats

◆ read() [7/15]

void datrw::binary::ibinstream::read ( std::string &  v)

Definition at line 118 of file ibinstream.cc.

References DATRW_assert, Mis, and read().

119  {
120  unsigned int length;
121  this->read(length);
122  aff::Series<char> s(length+1);
123  DATRW_assert(Mis.read(reinterpret_cast<char *>(s.pointer()),
124  length*sizeof(char)),
125  "ERROR (ibinstream::read): reading string");
126  s(s.l())='\0';
127  v=std::string(s.pointer());
128  } // void ibinstream::read(std::string& v)
#define DATRW_assert(C, M)
Check an assertion and report by throwing an exception.
Definition: error.h:92
std::istream & Mis
Definition: ibinstream.h:80
Here is the call graph for this function: