lemon/concept/graph.h
changeset 2130 244e108de26f
parent 2126 2c8adbee9fa6
child 2132 783b1d583be3
equal deleted inserted replaced
23:1d91b0248606 24:2a3f51faac77
    51       /// Defalult constructor.
    51       /// Defalult constructor.
    52 
    52 
    53       /// Defalult constructor.
    53       /// Defalult constructor.
    54       ///
    54       ///
    55       Graph() { }
    55       Graph() { }
    56 
    56       /// Class for identifying a node of the graph
    57       /// The base type of node iterators, 
    57 
    58       /// or in other words, the trivial node iterator.
    58       /// This class identifies a node of the graph. It also serves
    59 
    59       /// as a base class of the node iterators,
    60       /// This is the base type of each node iterator,
    60       /// thus they will convert to this type.
    61       /// thus each kind of node iterator converts to this.
       
    62       /// More precisely each kind of node iterator should be inherited 
       
    63       /// from the trivial node iterator.
       
    64       class Node {
    61       class Node {
    65       public:
    62       public:
    66         /// Default constructor
    63         /// Default constructor
    67 
    64 
    68         /// @warning The default constructor sets the iterator
    65         /// @warning The default constructor sets the iterator
   147         ///
   144         ///
   148         NodeIt& operator++() { return *this; }
   145         NodeIt& operator++() { return *this; }
   149       };
   146       };
   150     
   147     
   151     
   148     
   152       /// The base type of the edge iterators.
   149       /// Class for identifying an edge of the graph
   153 
   150 
   154       /// The base type of the edge iterators.
   151       /// This class identifies an edge of the graph. It also serves
   155       ///
   152       /// as a base class of the edge iterators,
       
   153       /// thus they will convert to this type.
   156       class Edge {
   154       class Edge {
   157       public:
   155       public:
   158         /// Default constructor
   156         /// Default constructor
   159 
   157 
   160         /// @warning The default constructor sets the iterator
   158         /// @warning The default constructor sets the iterator
   382 
   380 
   383       /// \brief Read write map of the nodes to type \c T.
   381       /// \brief Read write map of the nodes to type \c T.
   384       /// 
   382       /// 
   385       /// ReadWrite map of the nodes to type \c T.
   383       /// ReadWrite map of the nodes to type \c T.
   386       /// \sa Reference
   384       /// \sa Reference
   387       /// \warning Making maps that can handle bool type (NodeMap<bool>)
       
   388       /// needs some extra attention!
       
   389       template<class T> 
   385       template<class T> 
   390       class NodeMap : public ReadWriteMap< Node, T > {
   386       class NodeMap : public ReadWriteMap< Node, T > {
   391       public:
   387       public:
   392 
   388 
   393         ///\e
   389         ///\e
   407 
   403 
   408       /// \brief Read write map of the edges to type \c T.
   404       /// \brief Read write map of the edges to type \c T.
   409       ///
   405       ///
   410       /// Reference map of the edges to type \c T.
   406       /// Reference map of the edges to type \c T.
   411       /// \sa Reference
   407       /// \sa Reference
   412       /// \warning Making maps that can handle bool type (EdgeMap<bool>)
       
   413       /// needs some extra attention!
       
   414       template<class T> 
   408       template<class T> 
   415       class EdgeMap : public ReadWriteMap<Edge,T> {
   409       class EdgeMap : public ReadWriteMap<Edge,T> {
   416       public:
   410       public:
   417 
   411 
   418         ///\e
   412         ///\e