SeqAn3  3.0.1
The Modern C++ library for sequence analysis.
static_band.hpp
Go to the documentation of this file.
1 // -----------------------------------------------------------------------------------------------------
2 // Copyright (c) 2006-2020, Knut Reinert & Freie Universität Berlin
3 // Copyright (c) 2016-2020, 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 
16 #include <seqan3/std/concepts>
17 
18 namespace seqan3
19 {
20 
25 {
26 public:
30  constexpr static_band() noexcept = default;
31  constexpr static_band(static_band const &) noexcept = default;
32  constexpr static_band(static_band &&) noexcept = default;
33  constexpr static_band & operator=(static_band const &) noexcept = default;
34  constexpr static_band & operator=(static_band &&) noexcept = default;
35  ~static_band() noexcept = default;
36 
48  template <std::integral input_value_t>
50  : lower_bound{lower.get()}, upper_bound{upper.get()}
51  {
52  if (lower.get() > upper.get())
53  {
54  throw std::invalid_argument("The upper boundary must not be smaller than the lower boundary.");
55  }
56  }
58 
63 };
64 
65 } // namespace seqan3
bound.hpp
Provides seqan3::lower_bound and seqan3::upper_bound.
seqan3::lower_bound
Type for a lower boundary.
Definition: bound.hpp:26
seqan3::upper_bound
Type for an upper boundary.
Definition: bound.hpp:37
seqan3::static_band
Data structure for a static band.
Definition: static_band.hpp:24
concepts
The Concepts library.
std::numeric_limits::lowest
T lowest(T... args)
seqan3::static_band::~static_band
~static_band() noexcept=default
Defaulted.
seqan3::static_band::static_band
constexpr static_band() noexcept=default
Defaulted.
seqan3::static_band::static_band
constexpr static_band(lower_bound< input_value_t > const lower, upper_bound< input_value_t > const upper)
Construction from seqan3::lower_bound and seqan3::upper_bound.
Definition: static_band.hpp:49
seqan3
The main SeqAn3 namespace.
Definition: aligned_sequence_concept.hpp:36
std::invalid_argument
seqan3::static_band::operator=
constexpr static_band & operator=(static_band const &) noexcept=default
Defaulted.
std::numeric_limits::max
T max(T... args)