Orbiter 2022
Combinatorial Objects
arc_generator_description.cpp
Go to the documentation of this file.
1/*
2 * arc_generator_description.cpp
3 *
4 * Created on: Jun 26, 2020
5 * Author: betten
6 */
7
8
9
10#include "orbiter.h"
11
12using namespace std;
13
14namespace orbiter {
15namespace layer5_applications {
16namespace apps_geometry {
17
18
20{
21
23 Control = NULL;
24 f_d = FALSE;
25 d = 0;
26
28 target_size = 0;
29
31
33 nb_E = 0;
34 //Surf = NULL;
37
39 //forbidden_point_set_string = NULL;
40
42 //std::string override_group_label;
43
44}
45
47{
48}
49
50int arc_generator_description::read_arguments(int argc, std::string *argv,
51 int verbose_level)
52{
53 int f_v = (verbose_level >= 1);
54 int i;
56
57
58 if (f_v) {
59 cout << "arc_generator_description::read_arguments" << endl;
60 }
61 for (i = 0; i < argc; i++) {
62
63 if (ST.stringcmp(argv[i], "-poset_classification_control") == 0) {
66 if (f_v) {
67 cout << "-poset_classification_control " << endl;
68 }
69 i += Control->read_arguments(argc - (i + 1),
70 argv + i + 1, verbose_level);
71
72 if (f_v) {
73 cout << "done reading -poset_classification_control " << endl;
74 cout << "i = " << i << endl;
75 cout << "argc = " << argc << endl;
76 if (i < argc) {
77 cout << "next argument is " << argv[i] << endl;
78 }
79 }
80 }
81 else if (ST.stringcmp(argv[i], "-d") == 0) {
82 f_d = TRUE;
83 d = ST.strtoi(argv[++i]);
84 if (f_v) {
85 cout << "-d " << d << endl;
86 }
87 }
88 else if (ST.stringcmp(argv[i], "-target_size") == 0) {
90 target_size = ST.strtoi(argv[++i]);
91 if (f_v) {
92 cout << "-target_size " << target_size << endl;
93 }
94 }
95 else if (ST.stringcmp(argv[i], "-conic_test") == 0) {
97 if (f_v) {
98 cout << "-conic_test " << endl;
99 }
100 }
101 else if (ST.stringcmp(argv[i], "-test_nb_Eckardt_points") == 0) {
103 nb_E = ST.strtoi(argv[++i]);
104 if (f_v) {
105 cout << "-test_nb_Eckardt_points " << nb_E << endl;
106 }
107 }
108 else if (ST.stringcmp(argv[i], "-affine") == 0) {
109 f_affine = TRUE;
110 if (f_v) {
111 cout << "-affine " << endl;
112 }
113 }
114 else if (ST.stringcmp(argv[i], "-no_arc_testing") == 0) {
116 if (f_v) {
117 cout << "-no_arc_testing " << endl;
118 }
119 }
120 else if (ST.stringcmp(argv[i], "-forbidden_point_set") == 0) {
123
124 i++;
125
126 Os.get_string_from_command_line(forbidden_point_set_string, argc, argv, i, verbose_level);
127 i--;
128 if (f_v) {
129 cout << "-f_has_forbidden_point_set " << forbidden_point_set_string << endl;
130 }
131 }
132 else if (ST.stringcmp(argv[i], "-override_group") == 0) {
134 override_group_label.assign(argv[++i]);
135 if (f_v) {
136 cout << "-override_group " << override_group_label << endl;
137 }
138 }
139 else if (ST.stringcmp(argv[i], "-end") == 0) {
140 break;
141 }
142 else {
143 if (f_v) {
144 cout << "ignoring argument " << argv[i] << endl;
145 }
146 }
147 } // next i
148
149 if (f_v) {
150 cout << "arc_generator_description::read_arguments done" << endl;
151 }
152 return i + 1;
153}
154
156{
158 Control->print();
159 }
160 if (f_d) {
161 cout << "-d " << d << endl;
162 }
163 if (f_target_size) {
164 cout << "-target_size " << target_size << endl;
165 }
166 if (f_conic_test) {
167 cout << "-conic_test " << endl;
168 }
170 cout << "-test_nb_Eckardt_points " << nb_E << endl;
171 }
172 if (f_affine) {
173 cout << "-affine " << endl;
174 }
175 if (f_no_arc_testing) {
176 cout << "-no_arc_testing " << endl;
177 }
179 cout << "-has_forbidden_point_set " << forbidden_point_set_string << endl;
180 }
181 if (f_override_group) {
182 cout << "-override_group " << override_group_label << endl;
183 }
184}
185
186
187}}}
188
189
190
functions related to strings and character arrays
void get_string_from_command_line(std::string &p, int argc, std::string *argv, int &i, int verbose_level)
to control the behavior of the poset classification algorithm
poset_classification::poset_classification_control * Control
Definition: tl_geometry.h:32
#define NEW_OBJECT(type)
Definition: foundations.h:638
#define TRUE
Definition: foundations.h:231
#define FALSE
Definition: foundations.h:234
the orbiter library for the classification of combinatorial objects