|
rogue
|
Typed accessor over a contiguous frame-data region. More...
#include <FrameAccessor.h>
Public Member Functions | |
| FrameAccessor (rogue::interfaces::stream::FrameIterator &iter, uint32_t size) | |
| Creates a typed accessor at the iterator location. | |
| T & | operator[] (const uint32_t offset) |
| Dereference by index. | |
| T & | at (const uint32_t offset) |
Returns element reference at offset with bounds checking. | |
| uint32_t | size () |
| Returns number of elements in this accessor. | |
| T * | begin () |
| Returns pointer to first element. | |
| T * | end () |
| Returns pointer one-past-last element. | |
Typed accessor over a contiguous frame-data region.
FrameAccessor<T> provides typed element access into frame payload data when the requested range is fully contained in a single underlying buffer span. This avoids per-byte iterator overhead in tight loops while preserving a checked construction step.
Definition at line 43 of file FrameAccessor.h.
|
inline |
Creates a typed accessor at the iterator location.
| iter | Frame iterator positioned at the first element. |
| size | Number of elements in the accessor. |
| rogue::GeneralError | If the range spans multiple buffers. |
Definition at line 59 of file FrameAccessor.h.
|
inline |
Returns element reference at offset with bounds checking.
| offset | Element index. |
| rogue::GeneralError | If offset >= size(). |
Definition at line 88 of file FrameAccessor.h.
|
inline |
Returns pointer to first element.
Definition at line 104 of file FrameAccessor.h.
|
inline |
Returns pointer one-past-last element.
Definition at line 109 of file FrameAccessor.h.
|
inline |
Dereference by index.
Returns element reference at offset without bounds checking.
| offset | Element index. |
Definition at line 77 of file FrameAccessor.h.
|
inline |
Returns number of elements in this accessor.
Definition at line 99 of file FrameAccessor.h.