*
* Note: Do we need this?
* Forward iterator would be really in-efficient compared to
- * getText(k) and getText(k, i, j).
+ * getText(k).
*
* TODO Define and implement const_reverse_iterator.
*/
virtual bool IsLessThan(uchar const *) const = 0;
/**
- * Counting queries
- *
+ * Counting queries
+ * Result is the number of occurrences.
+ */
+ virtual ulong Count(uchar const *) const = 0;
+ /**
+ * More counting queries
* Result is the number of documents.
*/
virtual unsigned CountPrefix(uchar const *) const = 0;
typedef std::vector<std::pair<DocId, TextPosition> > full_result;
virtual full_result FullContains(uchar const *) const = 0;
-
- /**
- *Debug
- *
- */
- virtual TextPosition Lookup(TextPosition) const = 0;
protected:
// Protected constructor; call the static function InitTextCollection().
TextCollection() { };