2 * File automatically generated by
3 * gengen 1.2 by Lorenzo Bettini
4 * http://www.gnu.org/software/gengen
7 #ifndef GROUP_OPTION_GEN_CLASS_H
8 #define GROUP_OPTION_GEN_CLASS_H
16 class group_option_gen_class
19 string Comparison_rule;
21 string group_var_name;
22 string number_required;
23 string package_var_name;
26 group_option_gen_class()
30 group_option_gen_class(const string &_Comparison_rule, const string &_group_name, const string &_group_var_name, const string &_number_required, const string &_package_var_name) :
31 Comparison_rule (_Comparison_rule), group_name (_group_name), group_var_name (_group_var_name), number_required (_number_required), package_var_name (_package_var_name)
36 generate_string(const string &s, ostream &stream, unsigned int indent)
38 if (!indent || s.find('\n') == string::npos)
44 string::size_type pos;
45 string::size_type start = 0;
46 string ind (indent, ' ');
47 while ( (pos=s.find('\n', start)) != string::npos)
49 stream << s.substr (start, (pos+1)-start);
51 if (start+1 <= s.size ())
54 if (start+1 <= s.size ())
55 stream << s.substr (start);
58 void set_Comparison_rule(const string &_Comparison_rule)
60 Comparison_rule = _Comparison_rule;
63 void set_group_name(const string &_group_name)
65 group_name = _group_name;
68 void set_group_var_name(const string &_group_var_name)
70 group_var_name = _group_var_name;
73 void set_number_required(const string &_number_required)
75 number_required = _number_required;
78 void set_package_var_name(const string &_package_var_name)
80 package_var_name = _package_var_name;
83 void generate_group_option(ostream &stream, unsigned int indent = 0);
87 #endif // GROUP_OPTION_GEN_CLASS_H