Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/moses-smt/mosesdecoder.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'phrase-extract/SyntaxNodeCollection.h')
-rw-r--r--phrase-extract/SyntaxNodeCollection.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/phrase-extract/SyntaxNodeCollection.h b/phrase-extract/SyntaxNodeCollection.h
index 405a77c5f..da0e1eca3 100644
--- a/phrase-extract/SyntaxNodeCollection.h
+++ b/phrase-extract/SyntaxNodeCollection.h
@@ -55,11 +55,13 @@ public:
return m_nodes;
};
- size_t GetNumWords() const {
- return m_numWords;
- }
+ //! Get the number of words (defined as 1 + the max end pos of any node).
+ std::size_t GetNumWords() const { return m_numWords; }
+
+ //! Clear the container (this deletes the SyntaxNodes).
void Clear();
+ //! Extract a SyntaxTree (assuming the collection's nodes constitute a tree).
std::auto_ptr<SyntaxTree> ExtractTree();
private: