// Generated by using Rcpp::compileAttributes() -> do not edit by hand
// Generator token: 10BE3573-1514-4C36-9D1C-5A225CD40393

#ifndef RCPP_markovmix_RCPPEXPORTS_H_GEN_
#define RCPP_markovmix_RCPPEXPORTS_H_GEN_

#include <Rcpp.h>

namespace markovmix {

    using namespace Rcpp;

    namespace {
        void validateSignature(const char* sig) {
            Rcpp::Function require = Rcpp::Environment::base_env()["require"];
            require("markovmix", Rcpp::Named("quietly") = true);
            typedef int(*Ptr_validate)(const char*);
            static Ptr_validate p_validate = (Ptr_validate)
                R_GetCCallable("markovmix", "_markovmix_RcppExport_validate");
            if (!p_validate(sig)) {
                throw Rcpp::function_not_exported(
                    "C++ function with signature '" + std::string(sig) + "' not found in markovmix");
            }
        }
    }

    inline List split_seq(const List& seq_list, size_t len) {
        typedef SEXP(*Ptr_split_seq)(SEXP,SEXP);
        static Ptr_split_seq p_split_seq = NULL;
        if (p_split_seq == NULL) {
            validateSignature("List(*split_seq)(const List&,size_t)");
            p_split_seq = (Ptr_split_seq)R_GetCCallable("markovmix", "_markovmix_split_seq");
        }
        RObject rcpp_result_gen;
        {
            RNGScope RCPP_rngScope_gen;
            rcpp_result_gen = p_split_seq(Shield<SEXP>(Rcpp::wrap(seq_list)), Shield<SEXP>(Rcpp::wrap(len)));
        }
        if (rcpp_result_gen.inherits("interrupted-error"))
            throw Rcpp::internal::InterruptedException();
        if (Rcpp::internal::isLongjumpSentinel(rcpp_result_gen))
            throw Rcpp::LongjumpException(rcpp_result_gen);
        if (rcpp_result_gen.inherits("try-error"))
            throw Rcpp::exception(Rcpp::as<std::string>(rcpp_result_gen).c_str());
        return Rcpp::as<List >(rcpp_result_gen);
    }

    inline NumericMatrix colsums_by_group(const List& value_list, size_t n_col) {
        typedef SEXP(*Ptr_colsums_by_group)(SEXP,SEXP);
        static Ptr_colsums_by_group p_colsums_by_group = NULL;
        if (p_colsums_by_group == NULL) {
            validateSignature("NumericMatrix(*colsums_by_group)(const List&,size_t)");
            p_colsums_by_group = (Ptr_colsums_by_group)R_GetCCallable("markovmix", "_markovmix_colsums_by_group");
        }
        RObject rcpp_result_gen;
        {
            RNGScope RCPP_rngScope_gen;
            rcpp_result_gen = p_colsums_by_group(Shield<SEXP>(Rcpp::wrap(value_list)), Shield<SEXP>(Rcpp::wrap(n_col)));
        }
        if (rcpp_result_gen.inherits("interrupted-error"))
            throw Rcpp::internal::InterruptedException();
        if (Rcpp::internal::isLongjumpSentinel(rcpp_result_gen))
            throw Rcpp::LongjumpException(rcpp_result_gen);
        if (rcpp_result_gen.inherits("try-error"))
            throw Rcpp::exception(Rcpp::as<std::string>(rcpp_result_gen).c_str());
        return Rcpp::as<NumericMatrix >(rcpp_result_gen);
    }

}

#endif // RCPP_markovmix_RCPPEXPORTS_H_GEN_
