9 should use Regexp library.
12 strip_pretty(String pret)
14 String cl(pret.left(pret.pos('(')-1));
15 int l = cl.lastPos(' ');
16 cl = cl.right(cl.len() -l);
21 strip_member(String pret)
23 String cl(pret.left(pret.lastPos(':')-2));
28 Dstream::identify_as(String name)
30 String mem(strip_pretty(name));
31 String cl(strip_member(mem));
33 if(!silent.elt_query(cl))
35 local_silence = silent[cl];
36 if (classname != cl && !local_silence) {
38 *os << "[" << classname << ":]";
44 Dstream::switch_output(String name,bool b)
51 Dstream::operator<<(String s)
56 for (const char *cp = s ; *cp; cp++)
61 case '(': indentlvl += INDTAB;
71 if (indentlvl<0) indentlvl = 0;
75 *os << '\n' << String (' ', indentlvl) << flush;
84 /** only output possibility. Delegates all conversion to String class.
87 Dstream::Dstream(ostream &r, const char * cfg_nm )
92 const char * fn =cfg_nm ? cfg_nm : ".dstreamrc";
94 ifstream ifs(fn); // can't open
101 Text_record r( cfg++);
103 silent[r[0]] = r[1].to_bool();