Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

Loading...
Searching...
No Matches
Module.h
Go to the documentation of this file.
1
32#pragma once
33
34#include <ogdf/basic/basic.h>
35
36#include <iosfwd>
37
38namespace ogdf {
39
40
50public:
52 enum class ReturnType {
53 Feasible,
54 Optimal,
55 NoFeasibleSolution,
56 TimeoutFeasible,
57 TimeoutInfeasible,
58 Error
59 };
60
62 Module() { }
63
64 virtual ~Module() { }
65
67 static bool isSolution(ReturnType ret) {
68 return ret == ReturnType::Feasible || ret == ReturnType::Optimal
69 || ret == ReturnType::TimeoutFeasible;
70 }
71};
72
73OGDF_EXPORT std::ostream& operator<<(std::ostream& os, const Module::ReturnType& r);
74
75}
Basic declarations, included by all source files.
Base class for modules.
Definition Module.h:49
Module()
Initializes a module.
Definition Module.h:62
ReturnType
The return type of a module.
Definition Module.h:52
virtual ~Module()
Definition Module.h:64
static bool isSolution(ReturnType ret)
Returns true iff ret indicates that the module returned a feasible solution.
Definition Module.h:67
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF dynamic library (shared object / DLL),...
Definition config.h:117
The namespace for all OGDF objects.
std::ostream & operator<<(std::ostream &os, const ogdf::Array< E, INDEX > &a)
Prints array a to output stream os.
Definition Array.h:983