alpar@96: /* -*- C++ -*- alpar@96: * alpar@96: * This file is a part of LEMON, a generic C++ optimization library alpar@96: * alpar@96: * Copyright (C) 2003-2008 alpar@96: * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport alpar@96: * (Egervary Research Group on Combinatorial Optimization, EGRES). alpar@96: * alpar@96: * Permission to use, modify and distribute this software is granted alpar@96: * provided that this copyright notice appears in all copies. For alpar@96: * precise terms see the accompanying LICENSE file. alpar@96: * alpar@96: * This software is provided "AS IS" with no warranty of any kind, alpar@96: * express or implied, and with no claim as to its suitability for any alpar@96: * purpose. alpar@96: * alpar@96: */ alpar@96: alpar@96: ///\ingroup paths alpar@96: ///\file alpar@96: ///\brief Classes for representing paths in digraphs. alpar@96: /// alpar@96: alpar@96: #ifndef LEMON_PATH_H alpar@96: #define LEMON_PATH_H alpar@96: alpar@96: #include alpar@96: #include alpar@96: alpar@96: #include alpar@96: #include alpar@96: #include alpar@96: alpar@96: namespace lemon { alpar@96: alpar@96: /// \addtogroup paths alpar@96: /// @{ alpar@96: alpar@96: alpar@96: /// \brief A structure for representing directed paths in a digraph. alpar@96: /// alpar@96: /// A structure for representing directed path in a digraph. alpar@96: /// \param Digraph The digraph type in which the path is. alpar@96: /// alpar@96: /// In a sense, the path can be treated as a list of arcs. The alpar@96: /// lemon path type stores just this list. As a consequence it alpar@96: /// cannot enumerate the nodes in the path and the zero length paths alpar@96: /// cannot store the source. alpar@96: /// alpar@96: /// This implementation is a back and front insertable and erasable alpar@96: /// path type. It can be indexed in O(1) time. The front and back alpar@96: /// insertion and erasure is amortized O(1) time. The alpar@96: /// impelementation is based on two opposite organized vectors. alpar@96: template alpar@96: class Path { alpar@96: public: alpar@96: alpar@96: typedef _Digraph Digraph; alpar@96: typedef typename Digraph::Arc Arc; alpar@96: alpar@96: /// \brief Default constructor alpar@96: /// alpar@96: /// Default constructor alpar@96: Path() {} alpar@96: alpar@96: /// \brief Template copy constructor alpar@96: /// alpar@96: /// This path can be initialized with any other path type. It just alpar@96: /// makes a copy of the given path. alpar@96: template alpar@96: Path(const CPath& cpath) { alpar@96: copyPath(*this, cpath); alpar@96: } alpar@96: alpar@96: /// \brief Template copy assignment alpar@96: /// alpar@96: /// This path can be initialized with any other path type. It just alpar@96: /// makes a copy of the given path. alpar@96: template alpar@96: Path& operator=(const CPath& cpath) { alpar@96: copyPath(*this, cpath); alpar@96: return *this; alpar@96: } alpar@96: alpar@96: /// \brief Lemon style iterator for path arcs alpar@96: /// alpar@96: /// This class is used to iterate on the arcs of the paths. alpar@96: class ArcIt { alpar@96: friend class Path; alpar@96: public: alpar@96: /// \brief Default constructor alpar@96: ArcIt() {} alpar@96: /// \brief Invalid constructor alpar@96: ArcIt(Invalid) : path(0), idx(-1) {} alpar@96: /// \brief Initializate the constructor to the first arc of path alpar@96: ArcIt(const Path &_path) alpar@96: : path(&_path), idx(_path.empty() ? -1 : 0) {} alpar@96: alpar@96: private: alpar@96: alpar@96: ArcIt(const Path &_path, int _idx) alpar@96: : path(&_path), idx(_idx) {} alpar@96: alpar@96: public: alpar@96: alpar@96: /// \brief Conversion to Arc alpar@96: operator const Arc&() const { alpar@96: return path->nth(idx); alpar@96: } alpar@96: alpar@96: /// \brief Next arc alpar@96: ArcIt& operator++() { alpar@96: ++idx; alpar@96: if (idx >= path->length()) idx = -1; alpar@96: return *this; alpar@96: } alpar@96: alpar@96: /// \brief Comparison operator alpar@96: bool operator==(const ArcIt& e) const { return idx==e.idx; } alpar@96: /// \brief Comparison operator alpar@96: bool operator!=(const ArcIt& e) const { return idx!=e.idx; } alpar@96: /// \brief Comparison operator alpar@96: bool operator<(const ArcIt& e) const { return idx alpar@96: void build(const CPath& path) { alpar@96: int len = path.length(); alpar@96: tail.reserve(len); alpar@96: for (typename CPath::ArcIt it(path); it != INVALID; ++it) { alpar@96: tail.push_back(it); alpar@96: } alpar@96: } alpar@96: alpar@96: template alpar@96: void buildRev(const CPath& path) { alpar@96: int len = path.length(); alpar@96: head.reserve(len); alpar@96: for (typename CPath::RevArcIt it(path); it != INVALID; ++it) { alpar@96: head.push_back(it); alpar@96: } alpar@96: } alpar@96: alpar@96: protected: alpar@96: typedef std::vector Container; alpar@96: Container head, tail; alpar@96: alpar@96: }; alpar@96: alpar@96: /// \brief A structure for representing directed paths in a digraph. alpar@96: /// alpar@96: /// A structure for representing directed path in a digraph. alpar@96: /// \param Digraph The digraph type in which the path is. alpar@96: /// alpar@96: /// In a sense, the path can be treated as a list of arcs. The alpar@96: /// lemon path type stores just this list. As a consequence it alpar@96: /// cannot enumerate the nodes in the path and the zero length paths alpar@96: /// cannot store the source. alpar@96: /// alpar@96: /// This implementation is a just back insertable and erasable path alpar@96: /// type. It can be indexed in O(1) time. The back insertion and alpar@96: /// erasure is amortized O(1) time. This implementation is faster alpar@96: /// then the \c Path type because it use just one vector for the alpar@96: /// arcs. alpar@96: template alpar@96: class SimplePath { alpar@96: public: alpar@96: alpar@96: typedef _Digraph Digraph; alpar@96: typedef typename Digraph::Arc Arc; alpar@96: alpar@96: /// \brief Default constructor alpar@96: /// alpar@96: /// Default constructor alpar@96: SimplePath() {} alpar@96: alpar@96: /// \brief Template copy constructor alpar@96: /// alpar@96: /// This path can be initialized with any other path type. It just alpar@96: /// makes a copy of the given path. alpar@96: template alpar@96: SimplePath(const CPath& cpath) { alpar@96: copyPath(*this, cpath); alpar@96: } alpar@96: alpar@96: /// \brief Template copy assignment alpar@96: /// alpar@96: /// This path can be initialized with any other path type. It just alpar@96: /// makes a copy of the given path. alpar@96: template alpar@96: SimplePath& operator=(const CPath& cpath) { alpar@96: copyPath(*this, cpath); alpar@96: return *this; alpar@96: } alpar@96: alpar@96: /// \brief Iterator class to iterate on the arcs of the paths alpar@96: /// alpar@96: /// This class is used to iterate on the arcs of the paths alpar@96: /// alpar@96: /// Of course it converts to Digraph::Arc alpar@96: class ArcIt { alpar@96: friend class SimplePath; alpar@96: public: alpar@96: /// Default constructor alpar@96: ArcIt() {} alpar@96: /// Invalid constructor alpar@96: ArcIt(Invalid) : path(0), idx(-1) {} alpar@96: /// \brief Initializate the constructor to the first arc of path alpar@96: ArcIt(const SimplePath &_path) alpar@96: : path(&_path), idx(_path.empty() ? -1 : 0) {} alpar@96: alpar@96: private: alpar@96: alpar@96: /// Constructor with starting point alpar@96: ArcIt(const SimplePath &_path, int _idx) alpar@96: : idx(_idx), path(&_path) {} alpar@96: alpar@96: public: alpar@96: alpar@96: ///Conversion to Digraph::Arc alpar@96: operator const Arc&() const { alpar@96: return path->nth(idx); alpar@96: } alpar@96: alpar@96: /// Next arc alpar@96: ArcIt& operator++() { alpar@96: ++idx; alpar@96: if (idx >= path->length()) idx = -1; alpar@96: return *this; alpar@96: } alpar@96: alpar@96: /// Comparison operator alpar@96: bool operator==(const ArcIt& e) const { return idx==e.idx; } alpar@96: /// Comparison operator alpar@96: bool operator!=(const ArcIt& e) const { return idx!=e.idx; } alpar@96: /// Comparison operator alpar@96: bool operator<(const ArcIt& e) const { return idx alpar@96: void build(const CPath& path) { alpar@96: int len = path.length(); alpar@96: data.resize(len); alpar@96: int index = 0; alpar@96: for (typename CPath::ArcIt it(path); it != INVALID; ++it) { alpar@96: data[index] = it;; alpar@96: ++index; alpar@96: } alpar@96: } alpar@96: alpar@96: template alpar@96: void buildRev(const CPath& path) { alpar@96: int len = path.length(); alpar@96: data.resize(len); alpar@96: int index = len; alpar@96: for (typename CPath::RevArcIt it(path); it != INVALID; ++it) { alpar@96: --index; alpar@96: data[index] = it;; alpar@96: } alpar@96: } alpar@96: alpar@96: protected: alpar@96: typedef std::vector Container; alpar@96: Container data; alpar@96: alpar@96: }; alpar@96: alpar@96: /// \brief A structure for representing directed paths in a digraph. alpar@96: /// alpar@96: /// A structure for representing directed path in a digraph. alpar@96: /// \param Digraph The digraph type in which the path is. alpar@96: /// alpar@96: /// In a sense, the path can be treated as a list of arcs. The alpar@96: /// lemon path type stores just this list. As a consequence it alpar@96: /// cannot enumerate the nodes in the path and the zero length paths alpar@96: /// cannot store the source. alpar@96: /// alpar@96: /// This implementation is a back and front insertable and erasable alpar@96: /// path type. It can be indexed in O(k) time, where k is the rank alpar@96: /// of the arc in the path. The length can be computed in O(n) alpar@96: /// time. The front and back insertion and erasure is O(1) time alpar@96: /// and it can be splited and spliced in O(1) time. alpar@96: template alpar@96: class ListPath { alpar@96: public: alpar@96: alpar@96: typedef _Digraph Digraph; alpar@96: typedef typename Digraph::Arc Arc; alpar@96: alpar@96: protected: alpar@96: alpar@96: // the std::list<> is incompatible alpar@96: // hard to create invalid iterator alpar@96: struct Node { alpar@96: Arc arc; alpar@96: Node *next, *prev; alpar@96: }; alpar@96: alpar@96: Node *first, *last; alpar@96: alpar@96: std::allocator alloc; alpar@96: alpar@96: public: alpar@96: alpar@96: /// \brief Default constructor alpar@96: /// alpar@96: /// Default constructor alpar@96: ListPath() : first(0), last(0) {} alpar@96: alpar@96: /// \brief Template copy constructor alpar@96: /// alpar@96: /// This path can be initialized with any other path type. It just alpar@96: /// makes a copy of the given path. alpar@96: template alpar@96: ListPath(const CPath& cpath) : first(0), last(0) { alpar@96: copyPath(*this, cpath); alpar@96: } alpar@96: alpar@96: /// \brief Destructor of the path alpar@96: /// alpar@96: /// Destructor of the path alpar@96: ~ListPath() { alpar@96: clear(); alpar@96: } alpar@96: alpar@96: /// \brief Template copy assignment alpar@96: /// alpar@96: /// This path can be initialized with any other path type. It just alpar@96: /// makes a copy of the given path. alpar@96: template alpar@96: ListPath& operator=(const CPath& cpath) { alpar@96: copyPath(*this, cpath); alpar@96: return *this; alpar@96: } alpar@96: alpar@96: /// \brief Iterator class to iterate on the arcs of the paths alpar@96: /// alpar@96: /// This class is used to iterate on the arcs of the paths alpar@96: /// alpar@96: /// Of course it converts to Digraph::Arc alpar@96: class ArcIt { alpar@96: friend class ListPath; alpar@96: public: alpar@96: /// Default constructor alpar@96: ArcIt() {} alpar@96: /// Invalid constructor alpar@96: ArcIt(Invalid) : path(0), node(0) {} alpar@96: /// \brief Initializate the constructor to the first arc of path alpar@96: ArcIt(const ListPath &_path) alpar@96: : path(&_path), node(_path.first) {} alpar@96: alpar@96: protected: alpar@96: alpar@96: ArcIt(const ListPath &_path, Node *_node) alpar@96: : path(&_path), node(_node) {} alpar@96: alpar@96: alpar@96: public: alpar@96: alpar@96: ///Conversion to Digraph::Arc alpar@96: operator const Arc&() const { alpar@96: return node->arc; alpar@96: } alpar@96: alpar@96: /// Next arc alpar@96: ArcIt& operator++() { alpar@96: node = node->next; alpar@96: return *this; alpar@96: } alpar@96: alpar@96: /// Comparison operator alpar@96: bool operator==(const ArcIt& e) const { return node==e.node; } alpar@96: /// Comparison operator alpar@96: bool operator!=(const ArcIt& e) const { return node!=e.node; } alpar@96: /// Comparison operator alpar@96: bool operator<(const ArcIt& e) const { return nodenext; alpar@96: } alpar@96: return node->arc; alpar@96: } alpar@96: alpar@96: /// \brief Initializes arc iterator to point to the nth arc. alpar@96: ArcIt nthIt(int n) const { alpar@96: Node *node = first; alpar@96: for (int i = 0; i < n; ++i) { alpar@96: node = node->next; alpar@96: } alpar@96: return ArcIt(*this, node); alpar@96: } alpar@96: alpar@96: /// \brief Length of the path. alpar@96: int length() const { alpar@96: int len = 0; alpar@96: Node *node = first; alpar@96: while (node != 0) { alpar@96: node = node->next; alpar@96: ++len; alpar@96: } alpar@96: return len; alpar@96: } alpar@96: alpar@96: /// \brief Returns whether the path is empty. alpar@96: bool empty() const { return first == 0; } alpar@96: alpar@96: /// \brief Resets the path to an empty path. alpar@96: void clear() { alpar@96: while (first != 0) { alpar@96: last = first->next; alpar@96: alloc.destroy(first); alpar@96: alloc.deallocate(first, 1); alpar@96: first = last; alpar@96: } alpar@96: } alpar@96: alpar@96: /// \brief Gives back the first arc of the path alpar@96: const Arc& front() const { alpar@96: return first->arc; alpar@96: } alpar@96: alpar@96: /// \brief Add a new arc before the current path alpar@96: void addFront(const Arc& arc) { alpar@96: Node *node = alloc.allocate(1); alpar@96: alloc.construct(node, Node()); alpar@96: node->prev = 0; alpar@96: node->next = first; alpar@96: node->arc = arc; alpar@96: if (first) { alpar@96: first->prev = node; alpar@96: first = node; alpar@96: } else { alpar@96: first = last = node; alpar@96: } alpar@96: } alpar@96: alpar@96: /// \brief Erase the first arc of the path alpar@96: void eraseFront() { alpar@96: Node *node = first; alpar@96: first = first->next; alpar@96: if (first) { alpar@96: first->prev = 0; alpar@96: } else { alpar@96: last = 0; alpar@96: } alpar@96: alloc.destroy(node); alpar@96: alloc.deallocate(node, 1); alpar@96: } alpar@96: alpar@96: /// \brief Gives back the last arc of the path. alpar@96: const Arc& back() const { alpar@96: return last->arc; alpar@96: } alpar@96: alpar@96: /// \brief Add a new arc behind the current path. alpar@96: void addBack(const Arc& arc) { alpar@96: Node *node = alloc.allocate(1); alpar@96: alloc.construct(node, Node()); alpar@96: node->next = 0; alpar@96: node->prev = last; alpar@96: node->arc = arc; alpar@96: if (last) { alpar@96: last->next = node; alpar@96: last = node; alpar@96: } else { alpar@96: last = first = node; alpar@96: } alpar@96: } alpar@96: alpar@96: /// \brief Erase the last arc of the path alpar@96: void eraseBack() { alpar@96: Node *node = last; alpar@96: last = last->prev; alpar@96: if (last) { alpar@96: last->next = 0; alpar@96: } else { alpar@96: first = 0; alpar@96: } alpar@96: alloc.destroy(node); alpar@96: alloc.deallocate(node, 1); alpar@96: } alpar@96: alpar@96: /// \brief Splicing the given path to the current path. alpar@96: /// alpar@96: /// It splices the \c tpath to the back of the current path and \c alpar@96: /// tpath becomes empty. The time complexity of this function is alpar@96: /// O(1). alpar@96: void spliceBack(ListPath& tpath) { alpar@96: if (first) { alpar@96: if (tpath.first) { alpar@96: last->next = tpath.first; alpar@96: tpath.first->prev = last; alpar@96: last = tpath.last; alpar@96: } alpar@96: } else { alpar@96: first = tpath.first; alpar@96: last = tpath.last; alpar@96: } alpar@96: tpath.first = tpath.last = 0; alpar@96: } alpar@96: alpar@96: /// \brief Splicing the given path to the current path. alpar@96: /// alpar@96: /// It splices the \c tpath before the current path and \c tpath alpar@96: /// becomes empty. The time complexity of this function alpar@96: /// is O(1). alpar@96: void spliceFront(ListPath& tpath) { alpar@96: if (first) { alpar@96: if (tpath.first) { alpar@96: first->prev = tpath.last; alpar@96: tpath.last->next = first; alpar@96: first = tpath.first; alpar@96: } alpar@96: } else { alpar@96: first = tpath.first; alpar@96: last = tpath.last; alpar@96: } alpar@96: tpath.first = tpath.last = 0; alpar@96: } alpar@96: alpar@96: /// \brief Splicing the given path into the current path. alpar@96: /// alpar@96: /// It splices the \c tpath into the current path before the alpar@96: /// position of \c it iterator and \c tpath becomes empty. The alpar@96: /// time complexity of this function is O(1). If the \c it is \c alpar@96: /// INVALID then it will splice behind the current path. alpar@96: void splice(ArcIt it, ListPath& tpath) { alpar@96: if (it.node) { alpar@96: if (tpath.first) { alpar@96: tpath.first->prev = it.node->prev; alpar@96: if (it.node->prev) { alpar@96: it.node->prev->next = tpath.first; alpar@96: } else { alpar@96: first = tpath.first; alpar@96: } alpar@96: it.node->prev = tpath.last; alpar@96: tpath.last->next = it.node; alpar@96: } alpar@96: } else { alpar@96: if (first) { alpar@96: if (tpath.first) { alpar@96: last->next = tpath.first; alpar@96: tpath.first->prev = last; alpar@96: last = tpath.last; alpar@96: } alpar@96: } else { alpar@96: first = tpath.first; alpar@96: last = tpath.last; alpar@96: } alpar@96: } alpar@96: tpath.first = tpath.last = 0; alpar@96: } alpar@96: alpar@96: /// \brief Spliting the current path. alpar@96: /// alpar@96: /// It splits the current path into two parts. The part before \c alpar@96: /// it iterator will remain in the current path and the part from alpar@96: /// the it will put into the \c tpath. If the \c tpath had arcs alpar@96: /// before the operation they will be removed first. The time alpar@96: /// complexity of this function is O(1) plus the clearing of \c alpar@96: /// tpath. If the \c it is \c INVALID then it just clears \c alpar@96: /// tpath. alpar@96: void split(ArcIt it, ListPath& tpath) { alpar@96: tpath.clear(); alpar@96: if (it.node) { alpar@96: tpath.first = it.node; alpar@96: tpath.last = last; alpar@96: if (it.node->prev) { alpar@96: last = it.node->prev; alpar@96: last->next = 0; alpar@96: } else { alpar@96: first = last = 0; alpar@96: } alpar@96: it.node->prev = 0; alpar@96: } alpar@96: } alpar@96: alpar@96: alpar@96: typedef True BuildTag; alpar@96: alpar@96: template alpar@96: void build(const CPath& path) { alpar@96: for (typename CPath::ArcIt it(path); it != INVALID; ++it) { alpar@96: addBack(it); alpar@96: } alpar@96: } alpar@96: alpar@96: template alpar@96: void buildRev(const CPath& path) { alpar@96: for (typename CPath::RevArcIt it(path); it != INVALID; ++it) { alpar@96: addFront(it); alpar@96: } alpar@96: } alpar@96: alpar@96: }; alpar@96: alpar@96: /// \brief A structure for representing directed paths in a digraph. alpar@96: /// alpar@96: /// A structure for representing directed path in a digraph. alpar@96: /// \param Digraph The digraph type in which the path is. alpar@96: /// alpar@96: /// In a sense, the path can be treated as a list of arcs. The alpar@96: /// lemon path type stores just this list. As a consequence it alpar@96: /// cannot enumerate the nodes in the path and the zero length paths alpar@96: /// cannot store the source. alpar@96: /// alpar@96: /// This implementation is completly static, so it cannot be alpar@96: /// modified exclude the assign an other path. It is intented to be alpar@96: /// used when you want to store a large number of paths because it is alpar@96: /// the most memory efficient path type in the lemon. alpar@96: template alpar@96: class StaticPath { alpar@96: public: alpar@96: alpar@96: typedef _Digraph Digraph; alpar@96: typedef typename Digraph::Arc Arc; alpar@96: alpar@96: /// \brief Default constructor alpar@96: /// alpar@96: /// Default constructor alpar@96: StaticPath() : len(0), arcs(0) {} alpar@96: alpar@96: /// \brief Template copy constructor alpar@96: /// alpar@96: /// This path can be initialized with any other path type. It just alpar@96: /// makes a copy of the given path. alpar@96: template alpar@96: StaticPath(const CPath& cpath) : arcs(0) { alpar@96: copyPath(*this, cpath); alpar@96: } alpar@96: alpar@96: /// \brief Destructor of the path alpar@96: /// alpar@96: /// Destructor of the path alpar@96: ~StaticPath() { alpar@96: if (arcs) delete[] arcs; alpar@96: } alpar@96: alpar@96: /// \brief Template copy assignment alpar@96: /// alpar@96: /// This path can be initialized with any other path type. It just alpar@96: /// makes a copy of the given path. alpar@96: template alpar@96: StaticPath& operator=(const CPath& cpath) { alpar@96: copyPath(*this, cpath); alpar@96: return *this; alpar@96: } alpar@96: alpar@96: /// \brief Iterator class to iterate on the arcs of the paths alpar@96: /// alpar@96: /// This class is used to iterate on the arcs of the paths alpar@96: /// alpar@96: /// Of course it converts to Digraph::Arc alpar@96: class ArcIt { alpar@96: friend class StaticPath; alpar@96: public: alpar@96: /// Default constructor alpar@96: ArcIt() {} alpar@96: /// Invalid constructor alpar@96: ArcIt(Invalid) : path(0), idx(-1) {} alpar@96: /// Initializate the constructor to the first arc of path alpar@96: ArcIt(const StaticPath &_path) alpar@96: : path(&_path), idx(_path.empty() ? -1 : 0) {} alpar@96: alpar@96: private: alpar@96: alpar@96: /// Constructor with starting point alpar@96: ArcIt(const StaticPath &_path, int _idx) alpar@96: : idx(_idx), path(&_path) {} alpar@96: alpar@96: public: alpar@96: alpar@96: ///Conversion to Digraph::Arc alpar@96: operator const Arc&() const { alpar@96: return path->nth(idx); alpar@96: } alpar@96: alpar@96: /// Next arc alpar@96: ArcIt& operator++() { alpar@96: ++idx; alpar@96: if (idx >= path->length()) idx = -1; alpar@96: return *this; alpar@96: } alpar@96: alpar@96: /// Comparison operator alpar@96: bool operator==(const ArcIt& e) const { return idx==e.idx; } alpar@96: /// Comparison operator alpar@96: bool operator!=(const ArcIt& e) const { return idx!=e.idx; } alpar@96: /// Comparison operator alpar@96: bool operator<(const ArcIt& e) const { return idx alpar@96: void build(const CPath& path) { alpar@96: len = path.length(); alpar@96: arcs = new Arc[len]; alpar@96: int index = 0; alpar@96: for (typename CPath::ArcIt it(path); it != INVALID; ++it) { alpar@96: arcs[index] = it; alpar@96: ++index; alpar@96: } alpar@96: } alpar@96: alpar@96: template alpar@96: void buildRev(const CPath& path) { alpar@96: len = path.length(); alpar@96: arcs = new Arc[len]; alpar@96: int index = len; alpar@96: for (typename CPath::RevArcIt it(path); it != INVALID; ++it) { alpar@96: --index; alpar@96: arcs[index] = it; alpar@96: } alpar@96: } alpar@96: alpar@96: private: alpar@96: int len; alpar@96: Arc* arcs; alpar@96: }; alpar@96: alpar@96: ///@} alpar@96: alpar@96: } // namespace lemon alpar@96: alpar@96: #endif // LEMON_PATH_H