Orbiter 2022
Combinatorial Objects
graph_classification_activity_description.cpp
Go to the documentation of this file.
1/*
2 * graph_classification_activity_description.cpp
3 *
4 * Created on: Apr 12, 2021
5 * Author: betten
6 */
7
8
9
10
11#include "orbiter.h"
12
13using namespace std;
14
15namespace orbiter {
16namespace layer5_applications {
17namespace apps_graph_theory {
18
19
21{
24
26
29
31 draw_options = NULL;
32}
33
35{
36}
37
39 int argc, std::string *argv,
40 int verbose_level)
41{
42 int f_v = (verbose_level >= 1);
43 int i;
45
46 if (f_v) {
47 cout << "graph_classification_activity_description::read_arguments" << endl;
48 }
49 for (i = 0; i < argc; i++) {
50 if (ST.stringcmp(argv[i], "-draw_level_graph") == 0) {
52 draw_level_graph_level = ST.strtoi(argv[++i]);
53 if (f_v) {
54 cout << "-draw_level_graph " << draw_level_graph_level << endl;
55 }
56 }
57 else if (ST.stringcmp(argv[i], "-draw_graphs") == 0) {
59 if (f_v) {
60 cout << "-draw_graphs " << endl;
61 }
62 }
63 else if (ST.stringcmp(argv[i], "-draw_graphs_at_level") == 0) {
65 draw_graphs_at_level_level = ST.strtoi(argv[++i]);
66 if (f_v) {
67 cout << "-draw_graphs_at_level " << draw_graphs_at_level_level << endl;
68 }
69 }
70 else if (ST.stringcmp(argv[i], "-draw_options") == 0) {
72
74 if (f_v) {
75 cout << "-draw_options " << endl;
76 }
77 i += draw_options->read_arguments(argc - (i + 1),
78 argv + i + 1, verbose_level);
79
80 if (f_v) {
81 cout << "done reading -draw_options " << endl;
82 cout << "i = " << i << endl;
83 cout << "argc = " << argc << endl;
84 if (i < argc) {
85 cout << "next argument is " << argv[i] << endl;
86 }
87 cout << "-f_draw_options " << endl;
88 }
89 }
90 else if (ST.stringcmp(argv[i], "-end") == 0) {
91 if (f_v) {
92 cout << "-end" << endl;
93 }
94 break;
95 }
96 else {
97 cout << "graph_classification_activity_description::read_arguments "
98 "unrecognized option " << argv[i] << endl;
99 }
100
101 } // next i
102 if (f_v) {
103 cout << "graph_classification_activity_description::read_arguments done" << endl;
104 }
105 return i + 1;
106}
107
108
110{
111 if (f_draw_level_graph) {
112 cout << "-draw_level_graph " << draw_level_graph_level << endl;
113 }
114 if (f_draw_graphs) {
115 cout << "-draw_graphs " << endl;
116 }
118 cout << "-draw_graphs_at_level " << draw_graphs_at_level_level << endl;
119 }
120 if (f_draw_options) {
121 cout << "-f_draw_options " << endl;
123 }
124}
125
126
127
128}}}
129
functions related to strings and character arrays
options for drawing an object of type layered_graph
Definition: graphics.h:457
int read_arguments(int argc, std::string *argv, int verbose_level)
#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