![]() |
Arene Base
Fundamental Utilities For Safety Critical C++
|
A const reference class to an inline_vector object, with size-erased type. More...
Public Types | |
| using | const_iterator = typename inline_vector_detail::vector_base<T>::const_iterator |
| The const iterator type of the underlying vector. | |
| using | iterator = const_iterator |
| The iterator type to be used in this const context. | |
| using | size_type = std::size_t |
| The size type. | |
| using | value_type = T |
| The value type. | |
Public Member Functions | |
| constexpr | const_vector_reference (external_vector< T > const &vec) |
| Construct a vector reference to the supplied external_vector. | |
| template<std::size_t Capacity> | |
| constexpr | const_vector_reference (inline_vector< T, Capacity > const &vec) |
| Construct a vector reference to the supplied inline_vector. | |
| constexpr | const_vector_reference (vector_reference< T > const ref) |
| Construct a const reference out of a non-const one. | |
| template<bool AreExceptionsEnabled = detail::are_exceptions_enabled::value, constraints< std::enable_if_t< AreExceptionsEnabled > > = nullptr> | |
| constexpr auto | at (size_type index) const -> T const & |
Obtain a const reference to the element with the specified index. | |
| constexpr auto | back () const noexcept -> T const & |
| Get a const reference to the last element. | |
| constexpr auto | begin () const noexcept -> const_iterator |
| Obtain a const iterator to the start of the vector. | |
| constexpr auto | capacity () const noexcept -> size_type |
| Get the capacity. | |
| constexpr auto | cbegin () const noexcept -> const_iterator |
| Obtain an const iterator to the start of the vector. | |
| constexpr auto | cend () const noexcept -> const_iterator |
| Obtain a const iterator to the end of the vector. | |
| constexpr auto | data () const noexcept -> T const * |
| Obtain a pointer to the stored elements. | |
| constexpr auto | empty () const noexcept -> bool |
| Check if the vector is empty. | |
| constexpr auto | end () const noexcept -> const_iterator |
| Obtain a const iterator to the end of the vector. | |
| constexpr auto | front () const noexcept -> T const & |
| Get a const reference to the first element. | |
| constexpr auto | max_size () const noexcept -> size_type |
| Check if the vector is empty. | |
| constexpr auto | operator[] (size_type index) const noexcept -> T const & |
| Obtain a const reference to the element with the specified index. | |
| constexpr auto | size () const noexcept -> size_type |
| Get the current number of live elements in the vector. | |
A const reference class to an inline_vector object, with size-erased type.
| T | The type of each element |
| using arene::base::const_vector_reference< T >::const_iterator = typename inline_vector_detail::vector_base<T>::const_iterator |
The const iterator type of the underlying vector.
| using arene::base::const_vector_reference< T >::iterator = const_iterator |
The iterator type to be used in this const context.
| using arene::base::const_vector_reference< T >::size_type = std::size_t |
The size type.
| using arene::base::const_vector_reference< T >::value_type = T |
The value type.
|
inlineexplicitconstexpr |
Construct a vector reference to the supplied inline_vector.
| Capacity | The maximum number of elements that can be stored |
| vec | The inline_vector to reference |
|
inlineexplicitconstexpr |
Construct a vector reference to the supplied external_vector.
| vec | The external_vector to reference |
|
inlineexplicitconstexpr |
Construct a const reference out of a non-const one.
| ref | The non-const reference class |
|
inlineconstexpr |
Obtain a const reference to the element with the specified index.
| AreExceptionsEnabled | Used to disable this overload if exceptions are not enabled. |
| index | The index of the element |
| std::out_of_range | if the index is out of range |
|
inlineconstexprnoexcept |
Get a const reference to the last element.
|
inlineconstexprnoexcept |
Obtain a const iterator to the start of the vector.
|
inlineconstexprnoexcept |
Get the capacity.
|
inlineconstexprnoexcept |
Obtain an const iterator to the start of the vector.
|
inlineconstexprnoexcept |
Obtain a const iterator to the end of the vector.
|
inlineconstexprnoexcept |
Obtain a pointer to the stored elements.
|
inlineconstexprnoexcept |
Check if the vector is empty.
true if the vector is empty, false otherwise
|
inlineconstexprnoexcept |
Obtain a const iterator to the end of the vector.
|
inlineconstexprnoexcept |
Get a const reference to the first element.
|
inlineconstexprnoexcept |
Check if the vector is empty.
true if the vector is empty, false otherwise
|
inlineconstexprnoexcept |
Obtain a const reference to the element with the specified index.
| index | The index of the element |
index must be less than size()
|
inlineconstexprnoexcept |
Get the current number of live elements in the vector.