#ifndef HASHED_SENTENCE_HDR #define HASHED_SENTENCE_HDR #include "concordia/common/config.hpp" #include "concordia/interval.hpp" #include #include /*! A sentence after hashing by the HashGenerator. The class holds the list of word codes and intervals representing original word positions in the sentence (char-based). */ class HashedSentence { public: /*! Constructor. */ HashedSentence(); /*! Destructor. */ virtual ~HashedSentence(); /*! Getter for original word positions list. \returns original word positions list */ std::vector getOriginalWordPositions() const { return _originalWordPositions; } /*! Getter for word codes list. \returns word codes list */ std::vector getWordCodes() const { return _wordCodes; } /*! Method for adding a word code to the list \param word code to be added */ void addWordCode(INDEX_CHARACTER_TYPE wordCode) { _wordCodes.push_back(wordCode); } /*! Method for adding an original word position to the list. \param original word position */ void addWordOriginalWordPosition(Interval & originalWordPosition) { _originalWordPositions.push_back(originalWordPosition); } private: std::vector _originalWordPositions; std::vector _wordCodes; }; #endif