compiler/cpp/src/generate/t_go_generator.cc
/**
 * Serializes all the members of a struct.
 *
 * @param tstruct The struct to serialize
 * @param prefix  String prefix to attach to all fields
 */
Serializes all the members of a struct.
@param tstruct The struct to serialize
@param prefix  String prefix to attach to all fields
Serializes all the members of a struct . @param tstruct The struct to serialize @param prefix String prefix to attach to all fields
void t_go_generator::generate_serialize_struct(ofstream &out,
                                               t_struct* tstruct,
                                               string prefix,
                                               string err) {
  out <<
    indent() << err << " = " << prefix << ".Write(oprot)" << endl <<
    indent() << "if " << err << " != nil { return thrift.NewTProtocolExceptionWriteStruct(" 
                      << "\"" << escape_string(tstruct->get_name()) << "\", " << err << "); }\n";
}
void t_go_generator :: generate_serialize_struct ( ofstream & out , t_struct * tstruct , string prefix , string err ) { out << indent ( ) << err << " " << prefix << " " << endl << indent ( ) << " " << err << " " << " \" " << escape_string ( tstruct -> get_name ( ) ) << " \" " << err << " \n " ; }
Serializes all the members of a struct.
Serializes all the members of a struct .