1
/* -*- mode: c++; c-basic-offset: 2; indent-tabs-mode: nil; -*-
2
* vim:expandtab:shiftwidth=2:tabstop=2:smarttab:
4
* Copyright (C) 2011 Monty Taylor
6
* This program is free software; you can redistribute it and/or modify
7
* it under the terms of the GNU General Public License as published by
8
* the Free Software Foundation; version 2 of the License.
10
* This program is distributed in the hope that it will be useful,
11
* but WITHOUT ANY WARRANTY; without even the implied warranty of
12
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
* GNU General Public License for more details.
15
* You should have received a copy of the GNU General Public License
16
* along with this program; if not, write to the Free Software
17
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
20
#ifndef DRIZZLED_MODULE_VERTEX_H
21
#define DRIZZLED_MODULE_VERTEX_H
25
#define BOOST_NO_HASH 1
26
#include <boost/graph/graph_traits.hpp>
27
#include <boost/graph/adjacency_list.hpp>
28
#include <boost/graph/topological_sort.hpp>
32
enum vertex_properties_t { vertex_properties };
37
template <> struct property_kind<drizzled::vertex_properties_t>
39
typedef vertex_property_tag type;
59
explicit Vertex(const std::string& name) :
63
Vertex(const std::string& name, Module *module) :
67
Vertex(const Vertex& old) :
71
Vertex& operator=(const Vertex& old)
77
const std::string &getName() const
81
void setModule(Module *module)
91
typedef std::pair<std::string, std::string> ModuleEdge;
92
typedef boost::adjacency_list<boost::vecS,
94
boost::bidirectionalS,
95
boost::property<boost::vertex_color_t,
96
boost::default_color_type,
97
boost::property<vertex_properties_t, Vertex> >
99
typedef boost::graph_traits<VertexGraph>::vertex_descriptor VertexDesc;
100
typedef std::vector<VertexDesc> VertexList;
102
typedef boost::graph_traits<VertexGraph>::vertex_iterator vertex_iter;
104
} /* namespace module */
105
} /* namespace vertex */
107
#endif /* DRIZZLED_MODULE_VERTEX_H */