COIN-OR::LEMON - Graph Library

Changeset 242:b255f25ad394 in lemon-0.x for src/work/alpar/emptygraph.h


Ignore:
Timestamp:
03/24/04 14:06:06 (16 years ago)
Author:
Alpar Juttner
Branch:
default
Phase:
public
Convert:
svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@341
Message:

DocFixes?

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/work/alpar/emptygraph.h

    r216 r242  
    33#define HUGO_EMPTYGRAPH_H
    44
     5///\file
     6///\brief Declaration of GraphSkeleton.
     7
    58#include <invalid.h>
    69
     
    1316  /// An empty graph class.
    1417 
    15   /// When you read this for the first time,
    16   /// please send an e-mail to alpar\@cs.elte.hu.
    17   ///
    1818  /// This class provides all the common features of a graph structure,
    1919  /// however completely without implementations and real data structures
     
    103103    };
    104104   
    105     /// This iterator goes trought the outgoing edges of a node.
    106 
    107     /// This iterator goes trought the \e outgoing edges of a certain node
     105    /// This iterator goes trough the outgoing edges of a node.
     106
     107    /// This iterator goes trough the \e outgoing edges of a certain node
    108108    /// of a graph.
    109109    /// Its usage is quite simple, for example you can count the number
     
    131131    };
    132132
    133     /// This iterator goes trought the incoming edges of a node.
    134 
    135     /// This iterator goes trought the \e incoming edges of a certain node
     133    /// This iterator goes trough the incoming edges of a node.
     134
     135    /// This iterator goes trough the \e incoming edges of a certain node
    136136    /// of a graph.
    137137    /// Its usage is quite simple, for example you can count the number
     
    179179    NodeIt &first(NodeIt &i) const { return i;}
    180180
     181    /// The first incoming edge.
     182    InEdgeIt &first(InEdgeIt &i, Node n) const { return i;}
    181183    /// The first outgoing edge.
    182     InEdgeIt &first(InEdgeIt &i, Node n) const { return i;}
    183     /// The first incoming edge.
    184184    OutEdgeIt &first(OutEdgeIt &i, Node n) const { return i;}
    185185    //  SymEdgeIt &first(SymEdgeIt &, Node) const { return i;}
     
    229229    ///Gives back the \e id of a node.
    230230
    231     ///\warning Not all graph structure provide this feature.
     231    ///\warning Not all graph structures provide this feature.
    232232    ///
    233233    int id(const Node) const { return 0;}
    234234    ///Gives back the \e id of an edge.
    235235
    236     ///\warning Not all graph structure provide this feature.
     236    ///\warning Not all graph structures provide this feature.
    237237    ///
    238238    int id(const Edge) const { return 0;}
     
    253253    Edge addEdge(Node tail, Node head) { return INVALID;}
    254254   
    255     /// Deletes a node.
    256    
    257     ///\warning Not all graph structure provide this feature.
    258     ///
    259     void erase(Node n) {}
    260     /// Deletes an edge.
    261 
    262     ///\warning Not all graph structure provide this feature.
    263     ///
    264     void erase(Edge e) {}
    265 
    266     /// Reset the graph.
     255    /// Resets the graph.
    267256
    268257    /// This function deletes all edges and nodes of the graph.
     
    272261    int nodeNum() const { return 0;}
    273262    int edgeNum() const { return 0;}
    274 
     263 
     264    /// Defalult constructor.
    275265    GraphSkeleton() {}
     266    ///Copy consructor.
    276267    GraphSkeleton(const GraphSkeleton &G) {}
    277268 
    278   
     269 
    279270
    280271    ///Read/write/reference map of the nodes to type \c T.
     
    344335  };
    345336
     337  /// An empty eraseable graph class.
     338 
     339  /// This class provides all the common features of an \e eraseable graph
     340  /// structure,
     341  /// however completely without implementations and real data structures
     342  /// behind the interface.
     343  /// All graph algorithms should compile with this class, but it will not
     344  /// run properly, of course.
     345  ///
     346  /// \todo This blabla could be replaced by a sepatate description about
     347  /// Skeletons.
     348  ///
     349  /// It can be used for checking the interface compatibility,
     350  /// or it can serve as a skeleton of a new graph structure.
     351  ///
     352  /// Also, you will find here the full documentation of a certain graph
     353  /// feature, the documentation of a real graph imlementation
     354  /// like @ref ListGraph or
     355  /// @ref SmartGraph will just refer to this structure.
     356  class EraseableGraphSkeleton : public GraphSkeleton
     357  {
     358  public:
     359    /// Deletes a node.
     360    void erase(Node n) {}
     361    /// Deletes an edge.
     362    void erase(Edge e) {}
     363
     364    /// Defalult constructor.
     365    GraphSkeleton() {}
     366    ///Copy consructor.
     367    GraphSkeleton(const GraphSkeleton &G) {}
     368  };
     369
     370 
    346371  // @}
    347372
Note: See TracChangeset for help on using the changeset viewer.