SeqAn3  3.2.0-rc.1
The Modern C++ library for sequence analysis.
complement.hpp
Go to the documentation of this file.
1 // -----------------------------------------------------------------------------------------------------
2 // Copyright (c) 2006-2022, Knut Reinert & Freie Universität Berlin
3 // Copyright (c) 2016-2022, Knut Reinert & MPI für molekulare Genetik
4 // This file may be used, modified and/or redistributed under the terms of the 3-clause BSD-License
5 // shipped with this file and also available at: https://github.com/seqan/seqan3/blob/master/LICENSE.md
6 // -----------------------------------------------------------------------------------------------------
7 
13 #pragma once
14 
15 #include <ranges>
16 
19 
20 namespace seqan3::views
21 {
68  [](auto const in)
69  {
70  static_assert(nucleotide_alphabet<decltype(in)>,
71  "The innermost value type must satisfy the nucleotide_alphabet.");
72  // call element-wise complement from the nucleotide_alphabet
73  return seqan3::complement(in);
74  })};
75 
76 } // namespace seqan3::views
Provides seqan3::nucleotide_alphabet.
A wrapper type around an existing view adaptor that enables "deep view" behaviour for that view.
Definition: deep.hpp:104
Provides seqan3::views::deep.
constexpr auto complement
Return the complement of a nucleotide object.
Definition: alphabet/nucleotide/concept.hpp:105
auto const complement
A view that converts a range of nucleotides to their complement.
Definition: complement.hpp:67
decltype(detail::transform< trait_t >(list_t{})) transform
Apply a transformation trait to every type in the list and return a seqan3::type_list of the results.
Definition: type_list/traits.hpp:469
A concept that indicates whether an alphabet represents nucleotides.
The SeqAn namespace for views.
Definition: char_strictly_to.hpp:22
The <ranges> header from C++20's standard library.