|
| Tuple () |
| Default construct raw storage. More...
|
|
| Tuple (const Tuple< T, N > &t) |
| Copy constructor. More...
|
|
Tuple< T, N > & | operator= (const Tuple< T, N > &t) |
| Copy constructor. More...
|
|
T * | access_private_ptr () const |
|
template<> |
TEUCHOSCORE_LIB_DLL_EXPORT
std::string | toString () const |
|
template<> |
TEUCHOSCORE_LIB_DLL_EXPORT
std::string | toString () const |
|
template<> |
TEUCHOSCORE_LIB_DLL_EXPORT
std::string | toString () const |
|
template<> |
TEUCHOSCORE_LIB_DLL_EXPORT
std::string | toString () const |
|
template<> |
TEUCHOSCORE_LIB_DLL_EXPORT
std::string | toString () const |
|
template<> |
TEUCHOSCORE_LIB_DLL_EXPORT
std::string | toString () const |
|
template<> |
TEUCHOSCORE_LIB_DLL_EXPORT
std::string | toString () const |
|
template<> |
TEUCHOSCORE_LIB_DLL_EXPORT
std::string | toString () const |
|
| ArrayView (ENull null_arg=null) |
| Constructor that initializes to NULL (implicitly or explicitly). More...
|
|
| ArrayView (T *p, size_type size, const ERCPNodeLookup rcpNodeLookup=RCP_ENABLE_NODE_LOOKUP) |
| Initialize view from raw memory. More...
|
|
| ArrayView (const ArrayView< T > &array) |
| Initialize from another ArrayView<T> object. More...
|
|
| ArrayView (std::vector< typename std::remove_const_t< T >> &vec) |
| Create a nonconst view of an std::vector<T>. More...
|
|
| ArrayView (const std::vector< typename std::remove_const_t< T >> &vec) |
| Create a const view of an std::vector<T>. More...
|
|
ArrayView< T > & | operator= (const ArrayView< T > &array) |
| Shallow copy assignment operator. More...
|
|
| ~ArrayView () |
| Destructor. More...
|
|
bool | is_null () const |
| Returns true if the underlying pointer is null. More...
|
|
size_type | size () const |
| The total number of items in the managed array. More...
|
|
std::string | toString () const |
| Convert an ArrayView<T> to an std::string More...
|
|
T * | getRawPtr () const |
| Return a raw pointer to beginning of array or NULL if unsized. More...
|
|
T * | data () const |
| Return a raw pointer to beginning of array. More...
|
|
T & | operator[] (size_type i) const |
| Random object access. More...
|
|
T & | front () const |
| Get the first element. More...
|
|
T & | back () const |
| Get the last element. More...
|
|
ArrayView< T > | view (size_type offset, size_type size) const |
| Return a view of a contiguous range of elements. More...
|
|
ArrayView< T > | operator() (size_type offset, size_type size) const |
| Return a view of a contiguous range of elements (calls view(offset, size)). More...
|
|
const ArrayView< T > & | operator() () const |
| Return *this (just for compatibility with Array and ArrayPtr). More...
|
|
ArrayView< const T > | getConst () const |
| Return a const view of a possibly nonconst view. More...
|
|
| operator ArrayView< const T > () const |
| Implicitly convert an ArrayView<T> to an ArrayView<const T>. More...
|
|
void | assign (const ArrayView< const T > &array) const |
| Copy the data from one array view object to this array view object. More...
|
|
iterator | begin () const |
| Return an iterator to beginning of the array of data. More...
|
|
iterator | end () const |
| Return an iterator to past the end of the array of data. More...
|
|
const ArrayView< T > & | assert_not_null () const |
| Throws NullReferenceError if this->get()==NULL , otherwise returns reference to *this . More...
|
|
const ArrayView< T > & | assert_in_range (size_type offset, size_type size) const |
| Throws NullReferenceError if this->get()==NULL orthis->get()!=NULL , throws RangeError if (offset < 0 || this->size() < offset+size , otherwise returns reference to *this More...
|
|
|
(Note that these are not member functions.)
|
template<typename T > |
Tuple< T, 1 > | tuple (const T &a) |
| Create a Tuple<T,1>. More...
|
|
template<typename T > |
Tuple< T, 2 > | tuple (const T &a, const T &b) |
| Create a Tuple<T,2>. More...
|
|
template<typename T > |
Tuple< T, 3 > | tuple (const T &a, const T &b, const T &c) |
| Create a Tuple<T,3>. More...
|
|
template<typename T > |
Tuple< T, 4 > | tuple (const T &a, const T &b, const T &c, const T &d) |
| Create a Tuple<T,4>. More...
|
|
template<typename T > |
Tuple< T, 5 > | tuple (const T &a, const T &b, const T &c, const T &d, const T &e) |
| Create a Tuple<T,5>. More...
|
|
template<typename T > |
Tuple< T, 6 > | tuple (const T &a, const T &b, const T &c, const T &d, const T &e, const T &f) |
| Create a Tuple<T,6>. More...
|
|
template<typename T > |
Tuple< T, 7 > | tuple (const T &a, const T &b, const T &c, const T &d, const T &e, const T &f, const T &g) |
| Create a Tuple<T,7>. More...
|
|
template<typename T > |
Tuple< T, 8 > | tuple (const T &a, const T &b, const T &c, const T &d, const T &e, const T &f, const T &g, const T &h) |
| Create a Tuple<T,8>. More...
|
|
template<typename T > |
Tuple< T, 9 > | tuple (const T &a, const T &b, const T &c, const T &d, const T &e, const T &f, const T &g, const T &h, const T &i) |
| Create a Tuple<T,9>. More...
|
|
template<typename T > |
Tuple< T, 10 > | tuple (const T &a, const T &b, const T &c, const T &d, const T &e, const T &f, const T &g, const T &h, const T &i, const T &j) |
| Create a Tuple<T,10>. More...
|
|
template<typename T > |
Tuple< T, 11 > | tuple (const T &a, const T &b, const T &c, const T &d, const T &e, const T &f, const T &g, const T &h, const T &i, const T &j, const T &k) |
| Create a Tuple<T,11>. More...
|
|
template<typename T > |
Tuple< T, 12 > | tuple (const T &a, const T &b, const T &c, const T &d, const T &e, const T &f, const T &g, const T &h, const T &i, const T &j, const T &k, const T &l) |
| Create a Tuple<T,12>. More...
|
|
template<typename T > |
Tuple< T, 13 > | tuple (const T &a, const T &b, const T &c, const T &d, const T &e, const T &f, const T &g, const T &h, const T &i, const T &j, const T &k, const T &l, const T &m) |
| Create a Tuple<T,13>. More...
|
|
template<typename T > |
Tuple< T, 14 > | tuple (const T &a, const T &b, const T &c, const T &d, const T &e, const T &f, const T &g, const T &h, const T &i, const T &j, const T &k, const T &l, const T &m, const T &n) |
| Create a Tuple<T,14>. More...
|
|
template<typename T > |
Tuple< T, 15 > | tuple (const T &a, const T &b, const T &c, const T &d, const T &e, const T &f, const T &g, const T &h, const T &i, const T &j, const T &k, const T &l, const T &m, const T &n, const T &o) |
| Create a Tuple<T,15>. More...
|
|
template<class T > |
ArrayView< T > | arrayView (T *p, typename ArrayView< T >::size_type size) |
| Construct a const or non-const view to const or non-const data. More...
|
|
template<class T > |
ArrayView< T > | arrayViewFromVector (std::vector< T > &vec) |
| Construct a non-const view of an std::vector. More...
|
|
template<class T > |
ArrayView< const T > | arrayViewFromVector (const std::vector< T > &vec) |
| Construct a const view of an std::vector. More...
|
|
template<class T > |
std::vector< T > | createVector (const ArrayView< T > &av) |
| Get a new std::vector<T> object out of an ArrayView<T> object. More...
|
|
template<class T > |
std::vector< T > | createVector (const ArrayView< const T > &av) |
| Get a new std::vector<T> object out of an ArrayView<const T> object. More...
|
|
template<class T > |
bool | is_null (const ArrayView< T > &av) |
| Returns true if av.is_null()==true . More...
|
|
template<class T > |
bool | nonnull (const ArrayView< T > &av) |
| Returns true if av.get()!=NULL . More...
|
|
template<class T > |
std::ostream & | operator<< (std::ostream &out, const ArrayView< T > &av) |
| Output stream inserter. More...
|
|
template<class T2 , class T1 > |
ArrayView< T2 > | av_const_cast (const ArrayView< T1 > &p1) |
| Const cast of underlying ArrayView type from const T* to T* . More...
|
|
template<class T2 , class T1 > |
ArrayView< T2 > | av_reinterpret_cast (const ArrayView< T1 > &p1) |
| Reinterpret cast of underlying ArrayView type from T1* to T2* . More...
|
|
template<typename T, int N>
class Teuchos::Tuple< T, N >
Statically sized simple array (tuple) class.
ToDo: Finish documentation!
Design Discussion
This class derives from ArrayView and therefore inherits all of the features line element access and iterators along with full runtime checking. It does so at the expense of a little extra data (an extra pointer and an extra integer). However, this overhead will be small for any reasonable size of N.
Definition at line 35 of file Teuchos_Tuple.hpp.