Changes in lemon/concepts/graph.h [263:be8a861d3bb7:580:2313edd0db0b] in lemon-main
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
lemon/concepts/graph.h
r263 r580 3 3 * This file is a part of LEMON, a generic C++ optimization library. 4 4 * 5 * Copyright (C) 2003-200 85 * Copyright (C) 2003-2009 6 6 * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport 7 7 * (Egervary Research Group on Combinatorial Optimization, EGRES). … … 21 21 ///\brief The concept of Undirected Graphs. 22 22 23 #ifndef LEMON_CONCEPT _GRAPH_H24 #define LEMON_CONCEPT _GRAPH_H23 #ifndef LEMON_CONCEPTS_GRAPH_H 24 #define LEMON_CONCEPTS_GRAPH_H 25 25 26 26 #include <lemon/concepts/graph_components.h> 27 #include <lemon/concepts/graph.h>28 27 #include <lemon/core.h> 29 28 … … 499 498 }; 500 499 501 /// \brief Read write map of the nodes to type \c T. 502 /// 503 /// ReadWrite map of the nodes to type \c T. 504 /// \sa Reference 500 /// \brief Reference map of the nodes to type \c T. 501 /// 502 /// Reference map of the nodes to type \c T. 505 503 template<class T> 506 class NodeMap : public Re adWriteMap< Node, T>504 class NodeMap : public ReferenceMap<Node, T, T&, const T&> 507 505 { 508 506 public: … … 515 513 private: 516 514 ///Copy constructor 517 NodeMap(const NodeMap& nm) : ReadWriteMap< Node, T >(nm) { } 515 NodeMap(const NodeMap& nm) : 516 ReferenceMap<Node, T, T&, const T&>(nm) { } 518 517 ///Assignment operator 519 518 template <typename CMap> … … 524 523 }; 525 524 526 /// \brief Read write map of the directed arcs to type \c T. 527 /// 528 /// Reference map of the directed arcs to type \c T. 529 /// \sa Reference 525 /// \brief Reference map of the arcs to type \c T. 526 /// 527 /// Reference map of the arcs to type \c T. 530 528 template<class T> 531 class ArcMap : public Re adWriteMap<Arc,T>529 class ArcMap : public ReferenceMap<Arc, T, T&, const T&> 532 530 { 533 531 public: … … 539 537 private: 540 538 ///Copy constructor 541 ArcMap(const ArcMap& em) : ReadWriteMap<Arc,T>(em) { } 539 ArcMap(const ArcMap& em) : 540 ReferenceMap<Arc, T, T&, const T&>(em) { } 542 541 ///Assignment operator 543 542 template <typename CMap> … … 548 547 }; 549 548 550 /// Read write map of the edges to type \c T. 551 552 /// Reference map of the arcs to type \c T. 553 /// \sa Reference 549 /// Reference map of the edges to type \c T. 550 551 /// Reference map of the edges to type \c T. 554 552 template<class T> 555 class EdgeMap : public Re adWriteMap<Edge,T>553 class EdgeMap : public ReferenceMap<Edge, T, T&, const T&> 556 554 { 557 555 public: … … 563 561 private: 564 562 ///Copy constructor 565 EdgeMap(const EdgeMap& em) : ReadWriteMap<Edge,T>(em) {} 563 EdgeMap(const EdgeMap& em) : 564 ReferenceMap<Edge, T, T&, const T&>(em) {} 566 565 ///Assignment operator 567 566 template <typename CMap> … … 603 602 /// \brief Opposite node on an arc 604 603 /// 605 /// \return the opposite of the given Node on the given Edge604 /// \return The opposite of the given node on the given edge. 606 605 Node oppositeNode(Node, Edge) const { return INVALID; } 607 606 608 607 /// \brief First node of the edge. 609 608 /// 610 /// \return the first node of the given Edge.609 /// \return The first node of the given edge. 611 610 /// 612 611 /// Naturally edges don't have direction and thus 613 /// don't have source and target node. But we use these two methods614 /// to query the two nodes of the arc. The direction of the arc615 /// which arises this way is called the inherent direction of the612 /// don't have source and target node. However we use \c u() and \c v() 613 /// methods to query the two nodes of the arc. The direction of the 614 /// arc which arises this way is called the inherent direction of the 616 615 /// edge, and is used to define the "default" direction 617 616 /// of the directed versions of the arcs. 618 /// \sa direction 617 /// \sa v() 618 /// \sa direction() 619 619 Node u(Edge) const { return INVALID; } 620 620 621 621 /// \brief Second node of the edge. 622 /// 623 /// \return The second node of the given edge. 624 /// 625 /// Naturally edges don't have direction and thus 626 /// don't have source and target node. However we use \c u() and \c v() 627 /// methods to query the two nodes of the arc. The direction of the 628 /// arc which arises this way is called the inherent direction of the 629 /// edge, and is used to define the "default" direction 630 /// of the directed versions of the arcs. 631 /// \sa u() 632 /// \sa direction() 622 633 Node v(Edge) const { return INVALID; } 623 634 … … 738 749 struct Constraints { 739 750 void constraints() { 751 checkConcept<BaseGraphComponent, _Graph>(); 740 752 checkConcept<IterableGraphComponent<>, _Graph>(); 741 753 checkConcept<IDableGraphComponent<>, _Graph>();
Note: See TracChangeset
for help on using the changeset viewer.