34#ifndef GRAPH_GRAPH_VERTEX_H
35#define GRAPH_GRAPH_VERTEX_H
43#ifndef GRAPH_GRAPH_GRAPHOBJECT_H
67 typedef std::set<Edge*> ESet;
101#ifndef AIMS_GRAPH_SIZE_NO_DEPREC_WARNING
103 "the number of edges. In a future release, size() will return the "
104 "number properties as it does in GenericObject")))
263 void addEdge(
Edge* edge);
269 void removeEdge(
Edge* edge);
299 return _edges.begin();
315 return _edges.begin();
331 return _edges.rbegin();
339 return _edges.rend();
347 return _edges.rbegin();
355 return _edges.rend();
#define __deprecated__(msg)
The abstract base class for all types of edges; edges are created and managed by Graphs.
GraphObject(const std::string &s)
The programmer should not call the constructor of an abstract base class.
Vertices are created and managed by Graphs.
std::set< Edge * > edgesTo(const Vertex *vertex) const
Returns the edges linking this vertex to a given vertex.
ESet::reverse_iterator reverse_iterator
Vertex * randomNeighbour() const
Return a random neighbour (CAUTION!
Vertex(std::string s)
The programmer should not call the constructor.
bool hasEdge(const Edge *edge) const
Is a given edge attached to this vertex?
size_t edgesSize() const
The edgesSize of a vertex is the number of attached edges.
std::set< Vertex * > outNeighbours() const
Find the vertices for which this vertex is the source.
virtual std::string type() const CARTO_OVERRIDE
iterator begin()
Get the beginning of the edge collection.
ESet::value_type value_type
std::set< Vertex * > inNeighbours() const
Find the vertices for which this vertex is the sink.
iterator end()
Get the end of the edge collection.
ESet::const_reference const_reference
size_t size() const __attribute__((__deprecated__("use edgesSize() for " "the number of edges. In a future release
friend class GraphFactory
export the constructors
ESet::pointer pointer
pointer is absent from MS Visual C++ / Intel Win32
reverse_iterator rend()
Get the end of the reversed edge collection.
ESet::reference reference
ESet::const_reverse_iterator const_reverse_iterator
std::set< Vertex * > neighbours() const
Same as outNeighbours.
virtual Vertex * cloneVertex() const
The programmer should not clone.
ESet::const_iterator const_iterator
reverse_iterator rbegin()
Get the beginning of the reversed edge collection.
friend class Graph
export addEdge and removeEdge
Vertex(const Vertex &x)
The programmer should not call the copy constructor.
#define DECLARE_GENERIC_OBJECT_TYPE(T)