89 constexpr size_t size() const noexcept {
return m_size; }
118 constexpr T&
at(
size_t pos)
const
121 throw std::out_of_range(
122 "UnirecArray::at: pos (which is %zu) "
123 ">= m_size (which is %zu)"),
132 throw std::runtime_error(
"Unirec array data type format mismatch");
An iterator for the UnirecArray class.
std::ptrdiff_t difference_type
reference operator*() const
bool operator==(const Iterator &other) const
bool operator!=(const Iterator &other) const
std::random_access_iterator_tag iterator_category
A wrapper class for a contiguous array of values with the same unirec fieldID.
constexpr T & operator[](size_t pos)
Returns a reference to the element at the specified position in the UniRec field array.
constexpr Iterator begin() const noexcept
Returns an iterator to the first element of the UniRec field array.
constexpr Iterator end() const noexcept
Returns an iterator to the element following the last element of the UniRec field array.
void checkDataType(ur_field_type_t fieldDataType) const
UnirecArray(T *dataPointer, size_t size, ur_field_id_t fieldID)
Constructs a UnirecArray object.
constexpr size_t size() const noexcept
Returns the number of elements in the UniRec field array.
constexpr T & at(size_t pos) const
Returns a reference to the element at the specified position in the UniRec field array,...
#define ur_get_type(field_id)
Get type of UniRec field Get type of any UniRec defined field.
constexpr ur_field_type_t getExpectedUnirecType()
Determines the expected UniRec field type for a given C++ type T.
This file contains functions for determining the expected UniRec type for various C++ types.
Definition of UniRec structures and functions.
int16_t ur_field_id_t
Type of UniRec field identifiers.