FlowEngine 7.530
Photogrammetry Software Development Kit
|
Holds a (mutable) non_owning pointer and a size Used to marshal memory buffers as arguments in a safely manner. More...
#include <CommonDef.h>
Public Member Functions | |
Buffer ()=default | |
Represents an empty buffer. | |
Buffer (T *d, Size s) | |
Construct a buffer from a (mutable) pointer and a size. | |
template<std::size_t N> | |
Buffer (T(&fixedSizeArray)[N]) | |
Implicit conversion from a fixed-size array. | |
Buffer (std::vector< T > &v) | |
Implicit conversion from a std::vector. | |
Buffer (std::vector< T > &&v)=delete | |
Prohibits implicit conversion from a temporary std::vector. | |
operator bool () const | |
Evaluates to true if this buffer holds valid data, false otherwise. | |
T * | begin () |
Iteration support. | |
T * | end () |
Iteration support. | |
T & | operator[] (std::size_t index) |
Indexed access. | |
const T & | operator[] (std::size_t index) const |
Indexed access. | |
Public Attributes | |
T * | data = nullptr |
Pointer to the (mutable) data. | |
Size | count = 0 |
Number of elements the pointer points to. | |
Holds a (mutable) non_owning pointer and a size Used to marshal memory buffers as arguments in a safely manner.
|
default |
Represents an empty buffer.
|
inline |
Construct a buffer from a (mutable) pointer and a size.
|
inline |
Implicit conversion from a fixed-size array.
|
inline |
Implicit conversion from a std::vector.
|
delete |
Prohibits implicit conversion from a temporary std::vector.
|
inline |
Iteration support.
|
inline |
Iteration support.
|
inlineexplicit |
Evaluates to true if this buffer holds valid data, false otherwise.
|
inline |
Indexed access.
|
inline |
Indexed access.
Size FlowEngine::Buffer< T >::count = 0 |
Number of elements the pointer points to.
T* FlowEngine::Buffer< T >::data = nullptr |
Pointer to the (mutable) data.