/*
 * SuffixArrayFromBWT.cpp
 *
 *  Created on: 17. 02. 2021
 *      Author: Martin Prokopic
 */

#include <registration/AlgoRegistration.hpp>
#include "SuffixArrayFromBWT.h"

namespace {

auto SuffixArrayFromBWT = registration::AbstractRegister <
        stringology::indexing::SuffixArrayFromBWT,
        indexes::stringology::SuffixArray < >,
        const string::LinearStringTerminatingSymbolBWT < > & > ( stringology::indexing::SuffixArrayFromBWT::construct ).setDocumentation (
                "Construct a suffix array of the decoded string from the transformed string. The terminating symbol is removed in the process and the suffix array is shifted accordingly.\n"
                "\n"
                "@tparam SymbolType\n"
                "@param str the input BWT-encoded string\n"
                "@return the suffix array of the original (decoded) string" );

auto SuffixArrayFromBWTWithData = registration::AbstractRegister <
        stringology::indexing::SuffixArrayFromBWT,
        indexes::stringology::SuffixArray < >,
        const string::LinearStringTerminatingSymbolBWT < > &,
        const indexes::stringology::BWTAuxiliaryData < > & > ( stringology::indexing::SuffixArrayFromBWT::construct ).setDocumentation (
        "Construct a suffix array of the decoded string from the transformed string, reusing precomputed auxiliary data.. The terminating symbol is removed in the process and the suffix array is shifted accordingly.\n"
        "Required data types are W_FORWARD_DECODE and M_OCC_PREFIX_SUM.\n"
        "\n"
        "@tparam SymbolType\n"
        "@param str the input BWT-encoded string\n"
        "@param data precomputed auxiliary data\n"
        "@return the suffix array of the original (decoded) string" );

} /* namespace */
