SeqAn3 3.4.0-rc.1
The Modern C++ library for sequence analysis.
Loading...
Searching...
No Matches
search/fm_index/concept.hpp
Go to the documentation of this file.
1// SPDX-FileCopyrightText: 2006-2024 Knut Reinert & Freie Universität Berlin
2// SPDX-FileCopyrightText: 2016-2024 Knut Reinert & MPI für molekulare Genetik
3// SPDX-License-Identifier: BSD-3-Clause
4
10#pragma once
11
12#include <concepts>
13#include <type_traits>
14
15#include <sdsl/suffix_arrays.hpp>
16
18
19namespace seqan3::detail
20{
21
22// ============================================================================
23// sdsl_index
24// ============================================================================
25
31template <typename t>
32concept sdsl_index = requires (t sdsl_index) {
33 typename t::size_type;
34
35 { sdsl_index.size() } -> std::same_as<typename t::size_type>;
36 { sdsl_index[0] }; // suffix array access
37 { sdsl_index.comp2char[0] } -> std::same_as<uint8_t>;
38 { sdsl_index.char2comp[0] } -> std::same_as<uint8_t>;
39 { sdsl_index.sigma };
40 { sdsl_index.C[0] };
41
42 requires requires (t sdsl_index,
43 typename t::char_type const c,
44 typename t::size_type const lb,
45 typename t::size_type const rb,
46 sdsl::int_vector<8> const text) {
47 { sdsl_index.bwt.rank(lb, c) };
48 { sdsl_index.wavelet_tree.lex_count(lb, rb, c) };
49 { sdsl::construct_im(sdsl_index, text, 0) };
50 };
51};
53
63} // namespace seqan3::detail
64
65namespace seqan3
66{
69enum text_layout : bool
70{
75};
76
77} // namespace seqan3
text_layout
The possible text layouts (single, collection) the seqan3::fm_index and seqan3::bi_fm_index can suppo...
Definition search/fm_index/concept.hpp:70
@ single
The text is a single range.
Definition search/fm_index/concept.hpp:72
@ collection
The text is a range of ranges.
Definition search/fm_index/concept.hpp:74
The main SeqAn3 namespace.
Definition aligned_sequence_concept.hpp:26
Provides platform and dependency checks.
Hide me