sparrow ..
|
#include <fixed_width_binary_reference.hpp>
Public Types | |
using | self_type = fixed_width_binary_reference<L> |
using | value_type = typename L::inner_value_type |
using | reference = typename L::inner_reference |
using | const_reference = typename L::inner_const_reference |
using | size_type = typename L::size_type |
using | difference_type = std::ptrdiff_t |
using | iterator = typename L::data_iterator |
using | const_iterator = typename L::const_data_iterator |
Public Member Functions | |
constexpr | fixed_width_binary_reference (L *layout, size_type index) |
Constructs a binary reference for the given layout and index. | |
constexpr | fixed_width_binary_reference (const fixed_width_binary_reference &) noexcept=default |
constexpr | fixed_width_binary_reference (fixed_width_binary_reference &&) noexcept=default |
template<std::ranges::sized_range T> requires mpl::convertible_ranges<T, typename L::inner_value_type> | |
constexpr self_type & | operator= (T &&rhs) |
Assignment from a sized range of binary data. | |
constexpr size_type | size () const |
Gets the size of the binary element in bytes. | |
constexpr iterator | begin () |
Gets mutable iterator to the beginning of binary data. | |
constexpr iterator | end () |
Gets mutable iterator to the end of binary data. | |
constexpr const_iterator | begin () const |
Gets const iterator to the beginning of binary data. | |
constexpr const_iterator | end () const |
Gets const iterator to the end of binary data. | |
constexpr const_iterator | cbegin () const |
Gets const iterator to the beginning of binary data. | |
constexpr const_iterator | cend () const |
Gets const iterator to the end of binary data. | |
template<std::ranges::input_range T> requires mpl::convertible_ranges<T, typename L::inner_value_type> | |
constexpr bool | operator== (const T &rhs) const |
Equality comparison with another range of binary data. | |
template<std::ranges::input_range T> requires mpl::convertible_ranges<T, typename L::inner_value_type> | |
constexpr auto | operator<=> (const T &rhs) const |
Three-way comparison with another range of binary data. | |
constexpr reference | operator[] (size_type i) |
Byte-level access to the binary element (unchecked). | |
constexpr const_reference | operator[] (size_type i) const |
Byte-level access to the binary element (const, unchecked). | |
constexpr reference | at (size_type i) |
Checked byte-level access to the binary element. | |
constexpr const_reference | at (size_type i) const |
Checked byte-level access to the binary element (const). | |
template<std::ranges::sized_range T> requires mpl::convertible_ranges<T, typename L::inner_value_type> | |
constexpr auto | operator= (T &&rhs) -> self_type & |
Definition at line 81 of file fixed_width_binary_reference.hpp.
using sparrow::fixed_width_binary_reference< L >::const_iterator = typename L::const_data_iterator |
Definition at line 92 of file fixed_width_binary_reference.hpp.
using sparrow::fixed_width_binary_reference< L >::const_reference = typename L::inner_const_reference |
Definition at line 88 of file fixed_width_binary_reference.hpp.
using sparrow::fixed_width_binary_reference< L >::difference_type = std::ptrdiff_t |
Definition at line 90 of file fixed_width_binary_reference.hpp.
using sparrow::fixed_width_binary_reference< L >::iterator = typename L::data_iterator |
Definition at line 91 of file fixed_width_binary_reference.hpp.
using sparrow::fixed_width_binary_reference< L >::reference = typename L::inner_reference |
Definition at line 87 of file fixed_width_binary_reference.hpp.
using sparrow::fixed_width_binary_reference< L >::self_type = fixed_width_binary_reference<L> |
Definition at line 85 of file fixed_width_binary_reference.hpp.
using sparrow::fixed_width_binary_reference< L >::size_type = typename L::size_type |
Definition at line 89 of file fixed_width_binary_reference.hpp.
using sparrow::fixed_width_binary_reference< L >::value_type = typename L::inner_value_type |
Definition at line 86 of file fixed_width_binary_reference.hpp.
|
constexpr |
Constructs a binary reference for the given layout and index.
layout | Pointer to the layout containing the binary data |
index | Index of the binary element in the layout |
Definition at line 307 of file fixed_width_binary_reference.hpp.
|
constexprdefaultnoexcept |
|
constexprdefaultnoexcept |
|
nodiscardconstexpr |
Checked byte-level access to the binary element.
i | Byte index (0 <= i < size()) |
std::out_of_range | if i >= size() |
Definition at line 402 of file fixed_width_binary_reference.hpp.
|
nodiscardconstexpr |
Checked byte-level access to the binary element (const).
i | Byte index (0 <= i < size()) |
std::out_of_range | if i >= size() |
Definition at line 412 of file fixed_width_binary_reference.hpp.
|
nodiscardconstexpr |
Gets mutable iterator to the beginning of binary data.
Definition at line 331 of file fixed_width_binary_reference.hpp.
|
nodiscardconstexpr |
Gets const iterator to the beginning of binary data.
Definition at line 343 of file fixed_width_binary_reference.hpp.
|
nodiscardconstexpr |
Gets const iterator to the beginning of binary data.
Definition at line 355 of file fixed_width_binary_reference.hpp.
|
nodiscardconstexpr |
Gets const iterator to the end of binary data.
Definition at line 361 of file fixed_width_binary_reference.hpp.
|
nodiscardconstexpr |
Gets mutable iterator to the end of binary data.
Definition at line 337 of file fixed_width_binary_reference.hpp.
|
nodiscardconstexpr |
Gets const iterator to the end of binary data.
Definition at line 349 of file fixed_width_binary_reference.hpp.
|
constexpr |
Three-way comparison with another range of binary data.
Performs lexicographical comparison of this binary element with another range.
T | Type of the range to compare with |
rhs | Range to compare with |
Definition at line 377 of file fixed_width_binary_reference.hpp.
|
constexpr |
Assignment from a sized range of binary data.
Assigns new binary data to the referenced element. The source range must have exactly the same size as the fixed width of this binary type.
T | Type of the source range |
rhs | Source range to assign from |
|
constexpr |
Definition at line 316 of file fixed_width_binary_reference.hpp.
|
constexpr |
Equality comparison with another range of binary data.
Compares this binary element with another range byte-by-byte.
T | Type of the range to compare with |
rhs | Range to compare with |
Definition at line 369 of file fixed_width_binary_reference.hpp.
|
nodiscardconstexpr |
Byte-level access to the binary element (unchecked).
i | Byte index (0 <= i < size()) |
Definition at line 389 of file fixed_width_binary_reference.hpp.
|
nodiscardconstexpr |
Byte-level access to the binary element (const, unchecked).
i | Byte index (0 <= i < size()) |
Definition at line 395 of file fixed_width_binary_reference.hpp.
|
nodiscardconstexpr |
Gets the size of the binary element in bytes.
Definition at line 325 of file fixed_width_binary_reference.hpp.