31#if defined(DistanceBreadthFirstVisitor_RECURSES)
32#error Recursive header files inclusion detected in DistanceBreadthFirstVisitor.h
35#define DistanceBreadthFirstVisitor_RECURSES
37#if !defined DistanceBreadthFirstVisitor_h
39#define DistanceBreadthFirstVisitor_h
45#include "DGtal/base/Common.h"
46#include "DGtal/base/ConstAlias.h"
47#include "DGtal/base/CountedPtr.h"
48#include "DGtal/graph/CUndirectedSimpleLocalGraph.h"
202 template <
typename TGraph,
203 typename TVertexFunctor,
204 typename TMarkSet =
typename TGraph::VertexSet >
213 typedef typename Graph::Size
Size;
215 typedef typename VertexFunctor::Value
Scalar;
229 struct Node :
public std::pair< Vertex, Scalar >
231 typedef std::pair< Vertex, Scalar >
Base;
242 return other.second < second;
246 return other.second <= second;
250 return other.second == second;
254 return other.second != second;
303 template <
typename VertexIterator>
306 VertexIterator b, VertexIterator e );
341 template <
typename TBackInsertionSequence>
388 template <
typename VertexPredicate>
389 void expand(
const VertexPredicate & authorized_vtx );
402 template <
typename VertexPredicate>
530 template <
typename TGraph,
typename TVertexFunctor,
typename TMarkSet >
540#include "DGtal/graph/DistanceBreadthFirstVisitor.ih"
547#undef DistanceBreadthFirstVisitor_RECURSES
Aim: This class encapsulates its parameter class so that to indicate to the user that the object/poin...
Aim: This class is useful to perform an exploration of a graph given a starting point or set (called ...
MarkSet visitedVertices() const
DistanceBreadthFirstVisitor(ConstAlias< Graph > graph, const VertexFunctor &distance, const Vertex &p)
const MarkSet & markedVertices() const
TVertexFunctor VertexFunctor
DistanceBreadthFirstVisitor(const DistanceBreadthFirstVisitor &other)
void pushAgain(const Node &node)
DistanceBreadthFirstVisitor(const Graph &graph, const VertexFunctor &distance, VertexIterator b, VertexIterator e)
const Graph & graph() const
void getCurrentLayer(TBackInsertionSequence &layer)
~DistanceBreadthFirstVisitor()
DistanceBreadthFirstVisitor & operator=(const DistanceBreadthFirstVisitor &other)
void expandLayer(const VertexPredicate &authorized_vtx)
std::vector< Vertex > VertexList
Internal data structure for storing vertices.
const Node & current() const
VertexFunctor::Value Scalar
void selfDisplay(std::ostream &out) const
std::priority_queue< Node > NodeQueue
Internal data structure for computing the distance ordering expansion.
void swap(DistanceBreadthFirstVisitor &other)
DistanceBreadthFirstVisitor< TGraph, TVertexFunctor, TMarkSet > Self
void expand(const VertexPredicate &authorized_vtx)
DistanceBreadthFirstVisitor()
DGtal is the top-level namespace which contains all DGtal functions and types.
std::ostream & operator<<(std::ostream &out, const ClosedIntegerHalfPlane< TSpace > &object)
std::pair< Vertex, Scalar > Base
bool operator<=(const Node &other) const
bool operator==(const Node &other) const
Node(const Node &other)=default
bool operator!=(const Node &other) const
Node(const Vertex &v, Scalar d)
bool operator<(const Node &other) const