COIN-OR::LEMON - Graph Library

Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • lemon/full_graph.h

    r782 r834  
    5252
    5353    Node operator()(int ix) const { return Node(ix); }
    54     int index(const Node& node) const { return node._id; }
     54    static int index(const Node& node) { return node._id; }
    5555
    5656    Arc arc(const Node& s, const Node& t) const {
     
    163163  /// only in the concept class.
    164164  ///
     165  /// This class provides constant time counting for nodes and arcs.
     166  ///
    165167  /// \note FullDigraph and FullGraph classes are very similar,
    166168  /// but there are two differences. While this class conforms only
     
    205207    /// completely static, the nodes can be indexed with integers from
    206208    /// the range <tt>[0..nodeNum()-1]</tt>.
     209    /// The index of a node is the same as its ID.
    207210    /// \sa index()
    208211    Node operator()(int ix) const { return Parent::operator()(ix); }
     
    213216    /// completely static, the nodes can be indexed with integers from
    214217    /// the range <tt>[0..nodeNum()-1]</tt>.
     218    /// The index of a node is the same as its ID.
    215219    /// \sa operator()()
    216     int index(Node node) const { return Parent::index(node); }
     220    static int index(const Node& node) { return Parent::index(node); }
    217221
    218222    /// \brief Returns the arc connecting the given nodes.
     
    288292
    289293    Node operator()(int ix) const { return Node(ix); }
    290     int index(const Node& node) const { return node._id; }
     294    static int index(const Node& node) { return node._id; }
    291295
    292296    Edge edge(const Node& u, const Node& v) const {
     
    536540  /// only in the concept class.
    537541  ///
     542  /// This class provides constant time counting for nodes, edges and arcs.
     543  ///
    538544  /// \note FullDigraph and FullGraph classes are very similar,
    539545  /// but there are two differences. While FullDigraph
     
    580586    /// completely static, the nodes can be indexed with integers from
    581587    /// the range <tt>[0..nodeNum()-1]</tt>.
     588    /// The index of a node is the same as its ID.
    582589    /// \sa index()
    583590    Node operator()(int ix) const { return Parent::operator()(ix); }
     
    588595    /// completely static, the nodes can be indexed with integers from
    589596    /// the range <tt>[0..nodeNum()-1]</tt>.
     597    /// The index of a node is the same as its ID.
    590598    /// \sa operator()()
    591     int index(Node node) const { return Parent::index(node); }
     599    static int index(const Node& node) { return Parent::index(node); }
    592600
    593601    /// \brief Returns the arc connecting the given nodes.
Note: See TracChangeset for help on using the changeset viewer.