/*!
* @class IndexWotd
*
* @implements StringTreeConcept
*
* @extends Index
*
* @headerfile <seqan/index.h>
*
* @brief An index based on a lazy suffix tree (see Giegerich et al., "Efficient
* implementation of lazy suffix trees").
*
* @signature template <typename TText, typename TSpec> class Index<TText,
* IndexWotd<TSpec> >;
*
* @tparam TText The @link TextConcept @endlink text type.
* @tparam TSpec The type for further specialization of the Index type.
*
* The fibres (see @link Index @endlink and @link Fibre @endlink) of this index
* are a partially sorted suffix array (see @link WOTDIndexFibres#WotdSA
* @endlink) and the wotd tree (see @link WOTDIndexFibres#WotdDir @endlink).
*
* Demo: Demo.Constraint Iterator
*
* @see WOTDIndexFibres
*
* @fn IndexWotd#indexSA
*
* @headerfile <seqan/index.h>
*
* @brief Shortcut for <tt>getFibre(.., WotdSA)</tt>.
*
* @signature TSa indexSA(index);
*
* @param[in] index The @link IndexWotd @endlink object holding the fibre.
*
* @return TSa A reference to the @link WOTDIndexFibres#WotdSA @endlink fibre
* (partially sorted suffix array).
*
* @fn IndexWotd#indexDir
*
* @headerfile <seqan/index.h>
*
* @brief Shortcut for <tt>getFibre(.., WotdDir())</tt>.
*
* @signature TFibre indexDir(index);
*
* @param[in] index The @link IndexWotd @endlink object holding the fibre.
*
* @return TFibre A reference to the @link WOTDIndexFibres#WotdDir @endlink
* fibre (tree structure).
*
* @fn IndexWotd#saAt
*
* @headerfile <seqan/index.h>
*
* @brief Shortcut for <tt>value(indexSA(..), ..)</tt>.
*
* @note Advanced functionality, not commonly used.
*
* @signature TValue saAt(position, index);
*
* @param[in] index The @link IndexWotd @endlink object holding the fibre.
* @param[in] position A position in the array on which the value should be
* accessed.
*
* @return TValue A reference or proxy to the value in the @link
* WOTDIndexFibres#WotdSA @endlink fibre. To be more precise, a
* reference to a position containing a value of type @link
* SAValue @endlink is returned (or a proxy).
*
* @fn IndexWotd#dirAt
*
* @headerfile <seqan/index.h>
*
* @brief Shortcut for <tt>value(indexDir(index), position)</tt>.
*
* @signature TFibre dirAt(position, index);
*
* @param[in] index The @link IndexWotd @endlink object holding the fibre.
* @param[in] position A position in the array on which the value should be
* accessed.
*
* @return TFibre A reference to the @link WOTDIndexFibres#WotdDir @endlink
* fibre.
*
* @fn IndexWotd#createWotdIndex
*
* @headerfile <seqan/index.h>
*
* @brief Builds a the WOTD index.
*
* @signature void createWotdIndex(sa, dir, text);
*
* @param[out] sa The resulting list in which all <i>q</i>-grams are sorted
* alphabetically.
* @param[out] dir The resulting array that indicates at which position in index
* the corresponding <i>q</i>-grams can be found.
* @param[in] text The sequence. Types: @link SequenceConcept @endlink
*
* The resulting <tt>index</tt> contains the sorted list of qgrams. For each
* possible <i>q</i>-gram pos contains the first position in index that
* corresponds to this <i>q</i>-gram.
*/