GridGraphBase

Declared in lemon/grid_graph.h, in the group Graph Structures; the same class on the Doxygen site.

class GridGraphBase

Subclassed by GraphExtender< GridGraphBase >

Public Types

typedef GridGraphBase Graph
typedef True NodeNumTag
typedef True EdgeNumTag
typedef True ArcNumTag
typedef True FindEdgeTag
typedef True FindArcTag

Public Functions

inline GridGraphBase()
inline Node operator()( int i , int j ) const
inline int col( Node n ) const
inline int row( Node n ) const
inline dim2::Point< int > pos( Node n ) const
inline int width() const
inline int height() const
inline int nodeNum() const
inline int edgeNum() const
inline int arcNum() const
inline Node u( Edge edge ) const
inline Node v( Edge edge ) const
inline Node source( Arc arc ) const
inline Node target( Arc arc ) const
inline int maxNodeId() const
inline int maxEdgeId() const
inline int maxArcId() const
inline Edge findEdge( Node u , Node v , Edge prev = INVALID ) const
inline Arc findArc( Node u , Node v , Arc prev = INVALID ) const
inline void first( Node & node ) const
inline void first( Edge & edge ) const
inline void first( Arc & arc ) const
inline void firstOut( Arc & arc , const Node & node ) const
inline void nextOut( Arc & arc ) const
inline void firstIn( Arc & arc , const Node & node ) const
inline void nextIn( Arc & arc ) const
inline void firstInc( Edge & edge , bool & dir , const Node & node ) const
inline void nextInc( Edge & edge , bool & dir ) const
inline Arc right( Node n ) const
inline Arc left( Node n ) const
inline Arc up( Node n ) const
inline Arc down( Node n ) const

Public Static Functions

static inline int id( Node node )
static inline int id( Edge edge )
static inline int id( Arc arc )
static inline Node nodeFromId( int id )
static inline Edge edgeFromId( int id )
static inline Arc arcFromId( int id )
static inline bool direction( Arc arc )
static inline Arc direct( Edge edge , bool dir )
static inline void next( Node & node )
static inline void next( Edge & edge )
static inline void next( Arc & arc )

Protected Functions

inline void construct( int width , int height )
class Node

Public Functions

inline Node()
inline Node(Invalid)
inline bool operator==( const Node node ) const
inline bool operator!=( const Node node ) const
inline bool operator<( const Node node ) const

Protected Functions

inline Node( int id )

Protected Attributes

int _id
class Edge

Public Functions

inline Edge()
inline Edge(Invalid)
inline bool operator==( const Edge edge ) const
inline bool operator!=( const Edge edge ) const
inline bool operator<( const Edge edge ) const

Protected Functions

inline Edge( int id )

Protected Attributes

int _id
class Arc

Public Functions

inline Arc()
inline Arc(Invalid)
inline operator Edge() const
inline bool operator==( const Arc arc ) const
inline bool operator!=( const Arc arc ) const
inline bool operator<( const Arc arc ) const

Protected Functions

inline Arc( int id )

Protected Attributes

int _id