20 #ifndef __CXXGRAPH_TYPEDEF_H__
21 #define __CXXGRAPH_TYPEDEF_H__
38 namespace PARTITIONING{
45 enum E_InputOutputFormat
53 typedef E_InputOutputFormat InputOutputFormat;
63 unsigned long long parent = 0;
64 unsigned long long rank = 0;
72 std::string errorMessage =
"";
73 double result = INF_DOUBLE;
81 bool negativeCycle =
false;
82 std::string errorMessage =
"";
89 inline T hash_combine(T& lhs,
const T& rhs) {
90 T result = lhs ^ (rhs + 0x9e3779b9 + (lhs << 6) + (lhs >> 2));
100 template <
class T1,
class T2>
101 std::size_t operator () (
const std::pair<T1,T2> &p)
const {
102 std::size_t h1 = std::hash<T1>{}(p.first);
103 std::size_t h2 = std::hash<T2>{}(p.second);
104 return hash_combine(h1, h2);
111 bool success =
false;
112 bool negativeCycle =
false;
113 std::string errorMessage =
"";
114 std::unordered_map<std::pair<std::string, std::string>, double,
pair_hash> result = {};
121 bool success =
false;
122 std::string errorMessage =
"";
123 std::vector<std::pair<std::string, std::string>> mst = {};
124 double mstCost = 0.0;
131 bool success =
false;
132 std::string errorMessage =
"";
133 std::unordered_map<unsigned long long, long> minDistanceMap = {};
143 template <
typename T>
144 using AdjacencyMatrix = std::unordered_map<const Node<T> *, std::vector<std::pair<const Node<T> *,
const Edge<T> *>>>;
146 template <
typename T>
147 using PartitionMap = std::unordered_map<unsigned int, std::shared_ptr<PARTITIONING::Partition<T>>>;
Struct that contains the information about Dijsktra's Algorithm results.
Definition: Typedef.hpp:79
Struct that contains the information about Dijsktra's Algorithm results.
Definition: Typedef.hpp:130
Struct that contains the information about Dijsktra's Algorithm results.
Definition: Typedef.hpp:70
Struct that contains the information about Floyd-Warshall Algorithm results.
Definition: Typedef.hpp:110
Struct that contains the information about Prim, Boruvka & Kruskal Algorithm results.
Definition: Typedef.hpp:120
Struct useful for union-find operations.
Definition: Typedef.hpp:62
Definition: Typedef.hpp:99