FACT++  1.0
template<char >
string Converter::GetString ( const char *&  ptr) const

Converts from a binary block into a string. The type of the expected value is defined by the template parameter.

Parameters
ptrA refrenece to the pointer of the binary representation to be interpreted. The pointer is incremented by the sizeof the type.
Template Parameters
TExpected type
Returns
The string

Definition at line 367 of file Converter.cc.

References GetString(), TT::str, and t.

368 {
369  const T &t = *reinterpret_cast<const T*>(ptr);
370 
371  ostringstream stream;
372  stream << t;
373  ptr += sizeof(T);
374 
375  return stream.str();
376 }
char str[20]
Definition: test_client.c:23
TT t
Definition: test_client.c:26

+ Here is the call graph for this function: