Changeset 1631:e15162d8eca1 in lemon-0.x
- Timestamp:
- 08/16/05 21:06:59 (19 years ago)
- Branch:
- default
- Phase:
- public
- Convert:
- svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@2139
- Files:
-
- 13 edited
Legend:
- Unmodified
- Added
- Removed
-
doc/graph_io.dox
r1540 r1631 123 123 \subsection write Writing a graph 124 124 125 The \c GraphWriter class provides the graph output. To write a graph 125 The \ref lemon::GraphWriter "GraphWriter" template class 126 provides the graph output. To write a graph 126 127 you should first give writing commands to the writer. You can declare 127 128 writing command as \c NodeMap or \c EdgeMap writing and labeled Node and … … 132 133 \endcode 133 134 134 The \c writeNodeMap() function declares a \c NodeMap writing command in the 135 \c GraphWriter. You should give a name to the map and the map 135 The \ref lemon::GraphWriter::writeNodeMap() "writeNodeMap()" 136 function declares a \c NodeMap writing command in the 137 \ref lemon::GraphWriter "GraphWriter". 138 You should give a name to the map and the map 136 139 object as parameters. The NodeMap writing command with name "id" should write a 137 140 unique map because it will be regarded as an ID map. … … 148 151 \endcode 149 152 150 With the \c writeEdgeMap() member function you can give an edge map 153 With the \ref lemon::GraphWriter::writeEdgeMap() "writeEdgeMap()" 154 member function you can give an edge map 151 155 writing command similar to the NodeMaps. 152 156 … … 161 165 \endcode 162 166 163 With \c writeNode() and \c writeEdge() functions you can designate Nodes and 167 With \ref lemon::GraphWriter::writeNode() "writeNode()" 168 and \ref lemon::GraphWriter::writeEdge() "writeEdge()" 169 functions you can designate Nodes and 164 170 Edges in the graph. For example, you can write out the source and target node 165 171 of a maximum flow instance. … … 172 178 \endcode 173 179 174 With \c writeAttribute() function you can write an attribute to the file. 180 With \ref lemon::GraphWriter::writeAttribute() "writeAttribute()" 181 function you can write an attribute to the file. 175 182 176 183 \code … … 179 186 \endcode 180 187 181 After you give all write commands you must call the \c run() member 188 After you give all write commands you must call the 189 \ref lemon::GraphWriter::run() "run()" member 182 190 function, which executes all the writing commands. 183 191 … … 190 198 The file to be read may contain several maps and labeled nodes or edges. 191 199 If you read a graph you need not read all the maps and items just those 192 that you need. The interface of the \c GraphReader is very similar to 193 the GraphWriter but the reading method does not depend on the order of the 200 that you need. The interface of the \ref lemon::GraphReader "GraphReader" 201 is very similar to 202 the \ref lemon::GraphWriter "GraphWriter" 203 but the reading method does not depend on the order of the 194 204 given commands. 195 205 … … 202 212 \endcode 203 213 204 The \c readNodeMap() function reads a map from the \c nodeset section. 214 The \ref lemon::GraphReader::readNodeMap() "readNodeMap()" 215 function reads a map from the \c nodeset section. 205 216 If there is a map that you do not want to read from the file and there are 206 217 whitespaces in the string represenation of the values then you should 207 call the \c skipNodeMap() template member function with proper parameters. 218 call the \ref lemon::GraphReader::skipNodeMap() "skipNodeMap()" 219 template member function with proper parameters. 208 220 209 221 \see QuotedStringReader … … 219 231 \endcode 220 232 221 With the \c readEdgeMap() member function you can give an edge map 233 With the \ref lemon::GraphReader::readEdgeMap() "readEdgeMap()" 234 member function you can give an edge map 222 235 reading command similar to the NodeMaps. 223 236 … … 227 240 \endcode 228 241 229 With \c readNode() and \c readEdge() functions you can read labeled Nodes and 242 With \ref lemon::GraphReader::readNode() "readNode()" 243 and \ref lemon::GraphReader::readEdge() "readEdge()" 244 functions you can read labeled Nodes and 230 245 Edges. 231 246 … … 237 252 \endcode 238 253 239 With \c readAttribute() function you can read an attribute from the file. 254 With \ref lemon::GraphReader::readAttribute() "readAttribute()" 255 function you can read an attribute from the file. 240 256 241 257 \code … … 246 262 \endcode 247 263 248 After you give all read commands you must call the \c run() member 264 After you give all read commands you must call the 265 \ref lemon::GraphReader::run() "run()" member 249 266 function, which executes all the commands. 250 267 … … 258 275 259 276 To read a map (on the nodes or edges) 260 the \c GraphReader should know how to read a Value from the given map. 277 the \ref lemon::GraphReader "GraphReader" 278 should know how to read a Value from the given map. 261 279 By the default implementation the input operator reads a value from 262 280 the stream and the type of the readed value is the value type of the given map. … … 338 356 \endcode 339 357 340 There are similar classes to the \c GraphReader ans \c GraphWriter 341 which handle the undirected graphs. These classes are the 342 \c UndirGraphReader and \UndirGraphWriter. 343 344 The \c readUndirMap() function reads an undirected map and the 345 \c readUndirEdge() reads an undirected edge from the file, 358 There are similar classes to the \ref lemon::GraphReader "GraphReader" and 359 \ref lemon::GraphWriter "GraphWriter" which 360 handle the undirected graphs. These classes are 361 the \ref lemon::UndirGraphReader "UndirGraphReader" 362 and \ref lemon::UndirGraphWriter "UndirGraphWriter". 363 364 The \ref lemon::UndirGraphReader::readUndirMap() "readUndirMap()" 365 function reads an undirected map and the 366 \ref lemon::UndirGraphReader::readUndirEdge() "readUndirEdge()" 367 reads an undirected edge from the file, 346 368 347 369 \code … … 365 387 character. The file may contains comment lines with \c # first character. 366 388 367 The \c LemonReader and \c LemonWriter gives a framework to read and 389 The \ref lemon::LemonReader "LemonReader" 390 and \ref lemon::LemonWriter "LemonWriter" 391 gives a framework to read and 368 392 write sections. There are various section reader and section writer 369 classes which can be attached to a \c LemonReader or a \c LemonWriter. 393 classes which can be attached to a \ref lemon::LemonReader "LemonReader" 394 or a \ref lemon::LemonWriter "LemonWriter". 370 395 371 396 There are default section readers and writers for reading and writing … … 373 398 the format described above. Other type of data can be handled with own 374 399 section reader and writer classes which are inherited from the 375 \c LemonReader::SectionReader or the \c LemonWriter::SectionWriter classes. 400 \c LemonReader::SectionReader or the 401 \ref lemon::LemonWriter::SectionWriter "LemonWriter::SectionWriter" 402 classes. 376 403 377 404 The next example defines a special section reader which reads the … … 415 442 In our example there is a network with symmetric links and there are assymetric 416 443 traffic request on the network. This construction can be stored in an 417 undirected graph and in a directed NewEdgeSetAdaptor class. The example418 shows the input with the LemonReaderclass:444 undirected graph and in a directed \c NewEdgeSetAdaptor class. The example 445 shows the input with the \ref lemon::LemonReader "LemonReader" class: 419 446 420 447 \code … … 434 461 \endcode 435 462 436 Because the GraphReader and the UndirGraphReader can be converted 437 to LemonReader and it can resolve the ID's of the items, the previous 438 result can be achived with the UndirGraphReader class, too. 463 Because both the \ref lemon::GraphReader "GraphReader" 464 and the \ref lemon::UndirGraphReader "UndirGraphReader" can be converted 465 to \ref lemon::LemonReader "LemonReader" 466 and it can resolve the ID's of the items, the previous 467 result can be achived with the \ref lemon::UndirGraphReader "UndirGraphReader" 468 class, too. 439 469 440 470 -
doc/graphs.dox
r1200 r1631 35 35 \ref lemon::concept::ExtendableGraph "ExtendableGraph" concept, 36 36 so you cannot delete individual edges or nodes. 37 \li \ref lemon::SymListGraph "SymListGraph" and38 \ref lemon::SymSmartGraph "SymSmartGraph" classes are very similar to39 \ref lemon::ListGraph "ListGraph" and \ref lemon::SmartGraph "SmartGraph".40 The difference is that whenever you add a41 new edge to the graph, it actually adds a pair of oppositely directed edges.42 They are linked together so it is possible to access the counterpart of an43 edge. An even more important feature is that using these classes you can also44 attach data to the edges in such a way that the stored data45 are shared by the edge pairs.46 37 \li \ref lemon::FullGraph "FullGraph" 47 38 implements a complete graph. It is a -
doc/license.dox
r1536 r1631 3 3 \page license License Terms 4 4 5 \verbinclude ../LICENSE5 \verbinclude LICENSE 6 6 7 7 */ -
lemon/bfs.h
r1624 r1631 699 699 ///if \c v is unreachable from the root(s) or \c v is a root. The 700 700 ///shortest path tree used here is equal to the shortest path tree used in 701 ///\ref predNode( Node v).701 ///\ref predNode(). 702 702 ///\pre Either \ref run() or \ref start() must be called before using 703 703 ///this function. … … 714 714 ///if \c v itself a root. 715 715 ///The shortest path tree used here is equal to the shortest path 716 ///tree used in \ref pred( Node v).716 ///tree used in \ref pred(). 717 717 ///\pre Either \ref run() or \ref start() must be called before 718 718 ///using this function. -
lemon/concept/graph.h
r1630 r1631 405 405 /// This constructor sets the iterator to the first edge of \c g. 406 406 ///@param g the graph 407 EdgeIt(const StaticGraph& ) { }407 EdgeIt(const StaticGraph& g) { } 408 408 /// Edge -> EdgeIt conversion 409 409 -
lemon/concept/graph_component.h
r1627 r1631 764 764 765 765 /// This class describes the common interface of the graph maps 766 /// (NodeMap, EdgeMap), that is \ref maps-page s"maps" which can be used to766 /// (NodeMap, EdgeMap), that is \ref maps-page "maps" which can be used to 767 767 /// associate data to graph descriptors (nodes or edges). 768 768 template <typename Graph, typename Item, typename _Value> -
lemon/concept/undir_graph.h
r1630 r1631 233 233 /// 234 234 /// In LEMON undirected graphs also fulfill the concept of directed 235 /// graphs (\ref lemon::concept:: Graph "Graph Concept"). For235 /// graphs (\ref lemon::concept::StaticGraph "Graph Concept"). For 236 236 /// explanation of this and more see also the page \ref undir_graphs, 237 237 /// a tutorial about undirected graphs. … … 558 558 /// This constructor sets the iterator to the first edge of \c g. 559 559 ///@param g the graph 560 EdgeIt(const UndirGraph &) { }560 EdgeIt(const UndirGraph &g) { } 561 561 /// Edge -> EdgeIt conversion 562 562 … … 606 606 ///@param n the node 607 607 ///@param g the graph 608 OutEdgeIt(const UndirGraph& , const Node&) { }608 OutEdgeIt(const UndirGraph& n, const Node& g) { } 609 609 /// Edge -> OutEdgeIt conversion 610 610 … … 655 655 ///@param n the node 656 656 ///@param g the graph 657 InEdgeIt(const UndirGraph& , const Node&) { }657 InEdgeIt(const UndirGraph& g, const Node& n) { } 658 658 /// Edge -> InEdgeIt conversion 659 659 -
lemon/dfs.h
r1540 r1631 709 709 ///if \c v is unreachable from the root(s) or \c v is a root. The 710 710 ///%DFS tree used here is equal to the %DFS tree used in 711 ///\ref predNode( Node v).711 ///\ref predNode(). 712 712 ///\pre Either \ref run() or \ref start() must be called before using 713 713 ///this function. … … 724 724 ///if \c v itself a root. 725 725 ///The %DFS tree used here is equal to the %DFS 726 ///tree used in \ref pred( Node v).726 ///tree used in \ref pred(). 727 727 ///\pre Either \ref run() or \ref start() must be called before 728 728 ///using this function. -
lemon/dijkstra.h
r1536 r1631 703 703 ///if \c v is unreachable from the root or if \c v=s. The 704 704 ///shortest path tree used here is equal to the shortest path tree used in 705 ///\ref predNode( Node v). \pre \ref run() must be called before using705 ///\ref predNode(). \pre \ref run() must be called before using 706 706 ///this function. 707 707 ///\todo predEdge could be a better name. … … 714 714 ///root to \c /v. It is INVALID if \c v is unreachable from the root or if 715 715 ///\c v=s. The shortest path tree used here is equal to the shortest path 716 ///tree used in \ref pred( Node v). \pre \ref run() must be called before716 ///tree used in \ref pred(). \pre \ref run() must be called before 717 717 ///using this function. 718 718 Node predNode(Node v) const { return (*_pred)[v]==INVALID ? INVALID: -
lemon/graph_adaptor.h
r1627 r1631 1421 1421 /// 1422 1422 /// \param _Graph The type of the graph which shares its node set with 1423 /// this class. Its interface must conform to the \ref skeleton::StaticGraph1423 /// this class. Its interface must conform to the \ref concept::StaticGraph 1424 1424 /// "StaticGraph" concept. 1425 1425 /// 1426 1426 /// In the edge extension and removing it conforms to the 1427 /// \ref skeleton::ExtendableGraph "ExtendableGraph" concept.1427 /// \ref concept::ExtendableGraph "ExtendableGraph" concept. 1428 1428 template <typename _Graph> 1429 1429 class NewEdgeSetAdaptor : … … 1513 1513 /// 1514 1514 /// \param _Graph The type of the graph which shares its node set with 1515 /// this class. Its interface must conform to the \ref skeleton::StaticGraph1515 /// this class. Its interface must conform to the \ref concept::StaticGraph 1516 1516 /// "StaticGraph" concept. 1517 1517 /// 1518 1518 /// In the edge extension and removing it conforms to the 1519 /// \ref skeleton::ExtendableGraph "ExtendableGraph" concept.1519 /// \ref concept::ExtendableGraph "ExtendableGraph" concept. 1520 1520 template <typename _Graph> 1521 1521 class NewUndirEdgeSetAdaptor : -
lemon/kruskal.h
r1603 r1631 52 52 /// \param g The graph the algorithm runs on. 53 53 /// It can be either \ref concept::StaticGraph "directed" or 54 /// \ref concept::Undir StaticGraph "undirected".54 /// \ref concept::UndirGraph "undirected". 55 55 /// If the graph is directed, the algorithm consider it to be 56 56 /// undirected by disregarding the direction of the edges. … … 89 89 /// \return The cost of the found tree. 90 90 /// 91 /// \warning If kruskal is run on an \ref undirected graph, be sure that the 91 /// \warning If kruskal is run on an 92 /// \ref lemon::concept::UndirGraph "undirected graph", be sure that the 92 93 /// map storing the tree is also undirected 93 94 /// (e.g. UndirListGraph::UndirEdgeMap<bool>, otherwise the values of the -
lemon/preflow.h
r1435 r1631 284 284 285 285 ///The preflow algorithm consists of two phases, this method runs 286 ///the second phase. After calling \ref phase1 and then \ref 287 ///phase2, \ref flow contains a maximum flow, \ref flowValue 286 ///the second phase. After calling \ref phase1() and then 287 ///\ref phase2(), 288 /// \ref flowMap() return a maximum flow, \ref flowValue 288 289 ///returns the value of a maximum flow, \ref minCut returns a 289 290 ///minimum cut, while the methods \ref minMinCut and \ref -
lemon/smart_graph.h
r1537 r1631 90 90 /// Maximum node ID. 91 91 ///\sa id(Node) 92 int maxId(Node = INVALID) const { return nodes.size()-1; }92 int maxId(Node) const { return nodes.size()-1; } 93 93 /// Maximum edge ID. 94 94 95 95 /// Maximum edge ID. 96 96 ///\sa id(Edge) 97 int maxId(Edge = INVALID) const { return edges.size()-1; }97 int maxId(Edge) const { return edges.size()-1; } 98 98 99 99 Node source(Edge e) const { return edges[e.n].source; } … … 103 103 104 104 /// The ID of a valid Node is a nonnegative integer not greater than 105 /// \ref max NodeId(). The range of the ID's is not surely continuous106 /// and the greatest node ID can be actually less then \ref max NodeId().105 /// \ref maxId(Node). The range of the ID's is not surely continuous 106 /// and the greatest node ID can be actually less then \ref maxId(Node). 107 107 /// 108 108 /// The ID of the \ref INVALID node is -1. … … 112 112 113 113 /// The ID of a valid Edge is a nonnegative integer not greater than 114 /// \ref max EdgeId(). The range of the ID's is not surely continuous115 /// and the greatest edge ID can be actually less then \ref max EdgeId().114 /// \ref maxId(Edge). The range of the ID's is not surely continuous 115 /// and the greatest edge ID can be actually less then \ref maxId(Edge). 116 116 /// 117 117 /// The ID of the \ref INVALID edge is -1.
Note: See TracChangeset
for help on using the changeset viewer.