lemon/list_graph.h
changeset 2128 509846825ddf
parent 2123 85c6f5e82108
child 2132 783b1d583be3
equal deleted inserted replaced
33:243bd05dbd2b 34:fb91c9da210d
   323   ///The most of the member functions and nested classes are
   323   ///The most of the member functions and nested classes are
   324   ///documented only in the concept class.
   324   ///documented only in the concept class.
   325   ///\sa concept::Graph.
   325   ///\sa concept::Graph.
   326 
   326 
   327   class ListGraph : public ExtendedListGraphBase {
   327   class ListGraph : public ExtendedListGraphBase {
       
   328   private:
       
   329     ///ListGraph is \e not copy constructible. Use GraphCopy() instead.
       
   330     
       
   331     ///ListGraph is \e not copy constructible. Use GraphCopy() instead.
       
   332     ///
       
   333     ListGraph(const ListGraph &) :ExtendedListGraphBase() {};
       
   334     ///\brief Assignment of ListGraph to another is \e not allowed.
       
   335     ///Use GraphCopy() instead.
       
   336 
       
   337     ///Assignment of ListGraph to another is \e not allowed.
       
   338     ///Use GraphCopy() instead.
       
   339     void operator=(const ListGraph &) {}
   328   public:
   340   public:
   329 
   341 
   330     typedef ExtendedListGraphBase Parent;
   342     typedef ExtendedListGraphBase Parent;
       
   343 
       
   344     /// Constructor
       
   345     
       
   346     /// Constructor.
       
   347     ///
       
   348     ListGraph() {}
   331 
   349 
   332     ///Add a new node to the graph.
   350     ///Add a new node to the graph.
   333     
   351     
   334     /// \return the new node.
   352     /// \return the new node.
   335     ///
   353     ///
   734   ///
   752   ///
   735   ///\todo Snapshot, reverseEdge(), changeTarget(), changeSource(), contract()
   753   ///\todo Snapshot, reverseEdge(), changeTarget(), changeSource(), contract()
   736   ///haven't been implemented yet.
   754   ///haven't been implemented yet.
   737   ///
   755   ///
   738   class ListUGraph : public ExtendedListUGraphBase {
   756   class ListUGraph : public ExtendedListUGraphBase {
       
   757   private:
       
   758     ///ListUGraph is \e not copy constructible. Use UGraphCopy() instead.
       
   759 
       
   760     ///ListUGraph is \e not copy constructible. Use UGraphCopy() instead.
       
   761     ///
       
   762     ListUGraph(const ListUGraph &) :ExtendedListUGraphBase()  {};
       
   763     ///\brief Assignment of ListUGraph to another is \e not allowed.
       
   764     ///Use UGraphCopy() instead.
       
   765 
       
   766     ///Assignment of ListUGraph to another is \e not allowed.
       
   767     ///Use UGraphCopy() instead.
       
   768     void operator=(const ListUGraph &) {}
   739   public:
   769   public:
       
   770     /// Constructor
       
   771     
       
   772     /// Constructor.
       
   773     ///
       
   774     ListUGraph() {}
       
   775 
   740     typedef ExtendedListUGraphBase Parent;
   776     typedef ExtendedListUGraphBase Parent;
   741     /// \brief Add a new node to the graph.
   777     /// \brief Add a new node to the graph.
   742     ///
   778     ///
   743     /// \return the new node.
   779     /// \return the new node.
   744     ///
   780     ///
  1129       }
  1165       }
  1130 
  1166 
  1131       edges[edge.id].next_out = first_free_edge;
  1167       edges[edge.id].next_out = first_free_edge;
  1132       first_free_edge = edge.id;
  1168       first_free_edge = edge.id;
  1133     }
  1169     }
  1134 
  1170  
       
  1171     ///\e
       
  1172     
       
  1173     ///\bug Undocumented
       
  1174     ///\bug Doesn't destruct the maps.
  1135     void clear() {
  1175     void clear() {
  1136       aNodes.clear();
  1176       aNodes.clear();
  1137       bNodes.clear();
  1177       bNodes.clear();
  1138       edges.clear();
  1178       edges.clear();
  1139       first_anode = -1;
  1179       first_anode = -1;