Span. Not owning data view. It incapsulated pointer to the continuous array with one or more T objects.
More...
#include <Span.h>
|
using | element_type = T |
|
using | value_type = typename std::remove_const< T >::type |
|
using | index_type = std::ptrdiff_t |
|
using | pointer = T * |
|
using | reference = T & |
|
using | iterator = pointer |
|
using | const_pointer = T const * |
|
using | const_reference = T const & |
|
using | const_iterator = const_pointer |
|
|
| Span (Span const &)=default |
|
Span & | operator= (Span const &)=default |
|
| Span (T *data, std::size_t size) |
| Constructor by pointer and size. More...
|
|
template<class ContiguousContainer > |
| Span (ContiguousContainer &&container) |
| Constructor by contiguous container. More...
|
|
template<class ContiguousContainer > |
Span & | operator= (ContiguousContainer &&container) |
| Assignment operator with contiguous container. More...
|
|
reference | operator[] (std::size_t index) |
| Square brackets operator for convenient acces to underlying array; param index Array index.
|
|
const_reference | operator[] (std::size_t index) const |
| Non-modifying square brackets operator for convenient acces to underlying array; param index Array index.
|
|
bool | empty () const |
| Returns true if the span is empty.
|
|
pointer | data () const |
| Returns a pointer to the beginning of the span.
|
|
std::size_t | size () const |
| Returns the number of elements in the span.
|
|
std::size_t | getSize () const |
| Returns the number of elements in the span.
|
|
void | setSize (std::size_t size) |
| Sets the number of elements in the span. Because the span is not owning, this method will no construct or destroy element. This method will not allocate or free memory.
|
|
iterator | begin () |
| Returns an iterator to the beginning of the span.
|
|
const_iterator | begin () const |
| Returns an const iterator to the beginning of the span.
|
|
const_iterator | cbegin () const |
| Returns an iterator to the beginning of the span.
|
|
iterator | end () |
| Returns an iterator to one past the end of the span.
|
|
const_iterator | end () const |
| Returns an const iterator to one past the end of the span.
|
|
const_iterator | cend () const |
| Returns an const iterator to one past the end of the span.
|
|
template<class T>
class fsdk::Span< T >
Span. Not owning data view. It incapsulated pointer to the continuous array with one or more T objects.
Constructor by pointer and size.
- Parameters
-
data | A pointer to the beginning of the range of elements |
size | The number of elements pointed to by data |
template<class T>
template<class ContiguousContainer >
Constructor by contiguous container.
- Parameters
-
container | The container to construct from |
template<class T>
template<class ContiguousContainer >
Assignment operator with contiguous container.
- Parameters
-
container | The container to assign from |
The documentation for this class was generated from the following file: