SeqAn3  3.0.0
The Modern C++ library for sequence analysis.
mask.hpp
Go to the documentation of this file.
1 // -----------------------------------------------------------------------------------------------------
2 // Copyright (c) 2006-2019, Knut Reinert & Freie Universität Berlin
3 // Copyright (c) 2016-2019, 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 <cassert>
17 
18 namespace seqan3
19 {
34 class mask : public alphabet_base<mask, 2, void>
35 {
36 private:
39 
41  friend base_t;
42 
43 public:
47  constexpr mask() : base_t{} {}
48  constexpr mask(mask const &) = default;
49  constexpr mask(mask &&) = default;
50  constexpr mask & operator=(mask const &) = default;
51  constexpr mask & operator=(mask &&) = default;
52  ~mask() = default;
53 
59  static const mask UNMASKED;
61  static const mask MASKED;
63 };
64 
65 mask constexpr mask::UNMASKED{mask{}.assign_rank(0)};
66 mask constexpr mask::MASKED {mask{}.assign_rank(1)};
67 } // namespace seqan3
constexpr mask & operator=(mask const &)=default
Defaulted.
The main SeqAn3 namespace.
~mask()=default
Provides seqan3::alphabet_base.
constexpr mask()
Defaulted.
Definition: mask.hpp:47
A CRTP-base that makes defining a custom alphabet easier.
Definition: alphabet_base.hpp:52
Implementation of a masked alphabet to be used for tuple composites.
Definition: mask.hpp:34