Alphabet specific customisations for builtin char types.
More...
#include <seqan3/alphabet/adaptation/char.hpp>
|
static constexpr char_type & | assign_char_to (char_type const chr2, char_type &chr) noexcept |
| Assign a char to the char type (same as calling = ). More...
|
|
static constexpr char_type & | assign_rank_to (decltype(alphabet::to_rank(char_type{})) const rank, char_type &chr) noexcept |
| Assigning a rank to a char is the same as assigning it a numeric value. More...
|
|
static constexpr char_type | to_char (char_type const chr) noexcept |
| Converting char to char is no-op (it will just return the value you pass in). More...
|
|
static constexpr auto | to_rank (char_type const chr) noexcept |
| Convert char to rank by casting to an unsigned integral type of same size. More...
|
|
|
static constexpr auto | alphabet_size |
| The number of values the char type can take (e.g. 256 for char ). More...
|
|
template<typename char_type>
struct seqan3::custom::alphabet< char_type >
Alphabet specific customisations for builtin char types.
- Template Parameters
-
char_type | One of char , char16_t , char32_t or wchar_t . |
◆ assign_char_to()
template<typename char_type >
static constexpr char_type& seqan3::custom::alphabet< char_type >::assign_char_to |
( |
char_type const |
chr2, |
|
|
char_type & |
chr |
|
) |
| |
|
inlinestaticconstexprnoexcept |
Assign a char to the char type (same as calling =
).
- Parameters
-
[in] | chr2 | The char value you wish to assign. |
[in,out] | chr | The alphabet letter that you wish to assign to. |
- Returns
- A reference to the alphabet letter you passed in.
◆ assign_rank_to()
template<typename char_type >
|
inlinestaticconstexprnoexcept |
Assigning a rank to a char is the same as assigning it a numeric value.
- Parameters
-
[in] | rank | The rank value you wish to assign. |
[in,out] | chr | The alphabet letter that you wish to assign to. |
- Returns
- A reference to the alphabet letter you passed in.
◆ to_char()
template<typename char_type >
|
inlinestaticconstexprnoexcept |
Converting char to char is no-op (it will just return the value you pass in).
- Parameters
-
[in] | chr | The alphabet letter that you wish to convert to char (no-op). |
- Returns
chr
.
◆ to_rank()
template<typename char_type >
|
inlinestaticconstexprnoexcept |
Convert char to rank by casting to an unsigned integral type of same size.
- Parameters
-
[in] | chr | The alphabet letter that you wish to convert to rank. |
- Returns
- The letter's value in the alphabet's rank type (usually a
uint*_t
).
◆ alphabet_size
template<typename char_type >
Initial value:=
detail::min_viable_uint_t<detail::size_in_values_v<char_type>>{detail::size_in_values_v<char_type>}
The number of values the char type can take (e.g. 256 for char
).
The documentation for this struct was generated from the following file: