diff options
| author | Benjamin Paassen <bpaassen@techfak.uni-bielefeld.de> | 2015-03-03 19:07:48 +0100 |
|---|---|---|
| committer | Benjamin Paassen <bpaassen@techfak.uni-bielefeld.de> | 2015-03-03 19:07:48 +0100 |
| commit | 68c66558cd7c8e64dd0d3b934ccb58603f8b9836 (patch) | |
| tree | b05ce644f4c117ca20c766ac7314534ade6770fc /src/core/model/Document.hpp | |
| parent | e2f008689e9199c43757ca095fbe1623088e0c1e (diff) | |
prevented cycles in DocumentEntity::searchStartAnchor
Diffstat (limited to 'src/core/model/Document.hpp')
| -rw-r--r-- | src/core/model/Document.hpp | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/src/core/model/Document.hpp b/src/core/model/Document.hpp index 81e2f41..2f82127 100644 --- a/src/core/model/Document.hpp +++ b/src/core/model/Document.hpp @@ -157,16 +157,18 @@ private: void invalidateSubInstance(); template <typename Iterator> - Rooted<Anchor> searchStartAnchorInField(Handle<AnnotationClass> desc, - const std::string &name, - Iterator begin, Iterator end); + Rooted<Anchor> searchStartAnchorInField( + Handle<AnnotationClass> desc, const std::string &name, Iterator begin, + Iterator end, std::unordered_set<const DocumentEntity *> &visited); - Rooted<Anchor> searchStartAnchorDownwards(Handle<AnnotationClass> desc, - const std::string &name); + Rooted<Anchor> searchStartAnchorDownwards( + Handle<AnnotationClass> desc, const std::string &name, + std::unordered_set<const DocumentEntity *> &visited); - Rooted<Anchor> searchStartAnchorUpwards(Handle<AnnotationClass> desc, - const std::string &name, - const DocumentEntity *child); + Rooted<Anchor> searchStartAnchorUpwards( + Handle<AnnotationClass> desc, const std::string &name, + const DocumentEntity *child, + std::unordered_set<const DocumentEntity *> &visited); protected: bool doValidate(Logger &logger) const; @@ -1090,4 +1092,4 @@ extern const Rtti Anchor; } } -#endif /* _OUSIA_MODEL_DOCUMENT_HPP_ */ +#endif /* _OUSIA_MODEL_DOCUMENT_HPP_ */
\ No newline at end of file |
