Changeset 825:a143f19f465b in lemon for lemon/static_graph.h
- Timestamp:
- 09/29/09 13:03:34 (15 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
lemon/static_graph.h
r823 r825 93 93 void nextIn(Arc& e) const { e.id = arc_next_in[e.id]; } 94 94 95 int id(const Node& n) const{ return n.id; }96 Node nodeFromId(int id) const{ return Node(id); }95 static int id(const Node& n) { return n.id; } 96 static Node nodeFromId(int id) { return Node(id); } 97 97 int maxNodeId() const { return node_num - 1; } 98 98 99 int id(const Arc& e) const{ return e.id; }100 Arc arcFromId(int id) const{ return Arc(id); }99 static int id(const Arc& e) { return e.id; } 100 static Arc arcFromId(int id) { return Arc(id); } 101 101 int maxArcId() const { return arc_num - 1; } 102 102 … … 269 269 /// This function returns the node with the given index. 270 270 /// \sa index() 271 Node node(int ix) const{ return Parent::nodeFromId(ix); }271 static Node node(int ix) { return Parent::nodeFromId(ix); } 272 272 273 273 /// \brief The arc with the given index. … … 275 275 /// This function returns the arc with the given index. 276 276 /// \sa index() 277 Arc arc(int ix) const{ return Parent::arcFromId(ix); }277 static Arc arc(int ix) { return Parent::arcFromId(ix); } 278 278 279 279 /// \brief The index of the given node. … … 281 281 /// This function returns the index of the the given node. 282 282 /// \sa node() 283 int index(Node node) const{ return Parent::id(node); }283 static int index(Node node) { return Parent::id(node); } 284 284 285 285 /// \brief The index of the given arc. … … 287 287 /// This function returns the index of the the given arc. 288 288 /// \sa arc() 289 int index(Arc arc) const{ return Parent::id(arc); }289 static int index(Arc arc) { return Parent::id(arc); } 290 290 291 291 /// \brief Number of nodes.
Note: See TracChangeset
for help on using the changeset viewer.