void config_reader::parse_debug_line(row<long>& dbg_line, ch_string& str_ln){ #ifdef FULL_DEBUG bj_ostream& os = bj_out; MARK_USED(os); const char* pt_in = str_ln.c_str(); dbg_line.clear(); long num_ln = 0; if(isalnum(*pt_in)){ skip_whitespace(pt_in, num_ln); while(isdigit(*pt_in) || isspace(*pt_in)){ if(isspace(*pt_in)){ pt_in++; continue; } //os << pt_in << "$\n"; long val = parse_long(pt_in, num_ln); //skip_whitespace(pt_in, num_ln); dbg_line.push(val); } } else { skip_line(pt_in, num_ln); } #endif }
void read_batch_instances(ch_string file_nm, row<satex_entry>& f_insts){ bj_ostream& os = bj_out; std::ifstream in_stm; in_stm.open(file_nm.c_str(), std::ios::binary); if(! in_stm.good() || ! in_stm.is_open()){ os << "NO " << file_nm << " FILE FOUND." << bj_eol; return; } ch_string str_ln; long num_ln = 0; f_insts.clear(); while(! in_stm.eof()){ std::getline(in_stm, str_ln); num_ln++; if(! str_ln.empty()){ satex_entry& n_inst = f_insts.inc_sz(); //os << "Lei:<<" << str_ln << ">>" << bj_eol; n_inst.parse_entry(str_ln, num_ln); } } in_stm.close(); }