SeqAn3 3.4.0-rc.1
The Modern C++ library for sequence analysis.
|
Score matrix iterator for the pairwise alignment using only a single column. More...
#include <seqan3/alignment/matrix/detail/score_matrix_single_column.hpp>
Public Types | |
Associated types | |
using | value_type = decltype(std::declval< matrix_column_t >()|transform_to_affine_cell) |
The value type. | |
using | reference = value_type |
The reference type. | |
using | pointer = void |
The pointer type. | |
using | difference_type = std::ptrdiff_t |
The difference type. | |
using | iterator_category = std::input_iterator_tag |
The iterator category. | |
Public Member Functions | |
Constructor, assignment and destructor | |
matrix_iterator () noexcept=default | |
Defaulted. | |
matrix_iterator (matrix_iterator const &) noexcept=default | |
Defaulted. | |
matrix_iterator (matrix_iterator &&) noexcept=default | |
Defaulted. | |
matrix_iterator & | operator= (matrix_iterator const &) noexcept=default |
Defaulted. | |
matrix_iterator & | operator= (matrix_iterator &&) noexcept=default |
Defaulted. | |
~matrix_iterator ()=default | |
Defaulted. | |
matrix_iterator (score_matrix_single_column &host_matrix, size_t const initial_column_id) noexcept | |
Initialises the iterator from the underlying matrix. | |
Element access | |
reference | operator* () const |
Returns the range over the current column. | |
Arithmetic operators | |
matrix_iterator & | operator++ () |
Move this to the next column. | |
void | operator++ (int) |
Move this to the next column. | |
Private Types | |
using | matrix_column_t = decltype(views::zip(std::declval< physical_column_t & >(), std::declval< physical_column_t & >(), std::declval< virtual_column_t & >())) |
The type of the zipped score column. | |
Private Attributes | |
size_t | current_column_id {} |
The current column index. | |
score_matrix_single_column * | host_ptr {nullptr} |
The pointer to the underlying matrix. | |
Static Private Attributes | |
static constexpr auto | transform_to_affine_cell |
The transform adaptor to convert the tuple from the zip view into a seqan3::detail::affine_cell_type. | |
Friends | |
Comparison operators | |
bool | operator== (matrix_iterator const &lhs, matrix_iterator const &rhs) noexcept |
Tests whether lhs == rhs . | |
bool | operator!= (matrix_iterator const &lhs, matrix_iterator const &rhs) noexcept |
Tests whether lhs != rhs . | |
Score matrix iterator for the pairwise alignment using only a single column.
Implements a counted iterator to simulate the iteration over the actual matrix. When dereferenced, the iterator returns a view over the allocated memory of the respective columns. The returned view zips the three columns into a single range and transforms the returned tuple to a seqan3::detail::affine_cell_proxy to simplify the access to the correct values without knowing the internal tuple layout returned by the seqan3::views::zip view.
|
inlineexplicitnoexcept |
Initialises the iterator from the underlying matrix.
[in] | host_matrix | The underlying matrix. |
[in] | initial_column_id | The initial column index. |
|
staticconstexprprivate |
The transform adaptor to convert the tuple from the zip view into a seqan3::detail::affine_cell_type.