equal
deleted
inserted
replaced
215 |
215 |
216 template <typename CPath> |
216 template <typename CPath> |
217 void buildRev(const CPath& path) { |
217 void buildRev(const CPath& path) { |
218 int len = path.length(); |
218 int len = path.length(); |
219 head.reserve(len); |
219 head.reserve(len); |
220 for (typename CPath::RevIt it(path); it != INVALID; ++it) { |
220 for (typename CPath::RevEdgeIt it(path); it != INVALID; ++it) { |
221 head.push_back(it); |
221 head.push_back(it); |
222 } |
222 } |
223 } |
223 } |
224 |
224 |
225 protected: |
225 protected: |
373 template <typename CPath> |
373 template <typename CPath> |
374 void buildRev(const CPath& path) { |
374 void buildRev(const CPath& path) { |
375 int len = path.length(); |
375 int len = path.length(); |
376 data.resize(len); |
376 data.resize(len); |
377 int index = len; |
377 int index = len; |
378 for (typename CPath::RevIt it(path); it != INVALID; ++it) { |
378 for (typename CPath::RevEdgeIt it(path); it != INVALID; ++it) { |
379 --index; |
379 --index; |
380 data[index] = it;; |
380 data[index] = it;; |
381 } |
381 } |
382 } |
382 } |
383 |
383 |
718 } |
718 } |
719 } |
719 } |
720 |
720 |
721 template <typename CPath> |
721 template <typename CPath> |
722 void buildRev(const CPath& path) { |
722 void buildRev(const CPath& path) { |
723 for (typename CPath::RevIt it(path); it != INVALID; ++it) { |
723 for (typename CPath::RevEdgeIt it(path); it != INVALID; ++it) { |
724 addFront(it); |
724 addFront(it); |
725 } |
725 } |
726 } |
726 } |
727 |
727 |
728 }; |
728 }; |
879 template <typename CPath> |
879 template <typename CPath> |
880 void buildRev(const CPath& path) { |
880 void buildRev(const CPath& path) { |
881 len = path.length(); |
881 len = path.length(); |
882 edges = new Edge[len]; |
882 edges = new Edge[len]; |
883 int index = len; |
883 int index = len; |
884 for (typename CPath::RevIt it(path); it != INVALID; ++it) { |
884 for (typename CPath::RevEdgeIt it(path); it != INVALID; ++it) { |
885 --index; |
885 --index; |
886 edges[index] = it; |
886 edges[index] = it; |
887 } |
887 } |
888 } |
888 } |
889 |
889 |