utilities
0.0
|
#include <memory.h>
Classes | |
class | MyIterator |
Public Types | |
using | Iterator = MyIterator< false > |
using | ConstIterator = MyIterator< true > |
typedef Iterator | iterator |
typedef ConstIterator | const_iterator |
using | reverse_iterator = std::reverse_iterator< Iterator > |
using | const_reverse_iterator = std::reverse_iterator< ConstIterator > |
Public Member Functions | |
vector (size_t const length=0) | |
Construct a vector of type T with managed storage. More... | |
vector (size_t const length, const T &value) | |
Construct a vector of type T with managed storage. More... | |
template<class InputIterator > | |
vector (InputIterator first, InputIterator last) | |
Construct a vector of type T with managed storage. More... | |
vector (std::initializer_list< T > il) | |
Construct a vector of type T with managed storage. More... | |
vector (const vector< T, _Alloc > &source) | |
vector<T> Copy constructor More... | |
vector< T, _Alloc > & | operator= (const vector< T, _Alloc > ©) |
Copy assignment operator. More... | |
virtual | ~vector ()=default |
T & | operator[] (size_t n) |
const T & | operator[] (size_t n) const |
template<class InputIterator > | |
void | assign (InputIterator first, InputIterator last) |
Assign new contents to the vector, replacing its current contents. More... | |
void | assign (const T &value) |
Assign new contents to the vector, replacing its current contents. More... | |
void | assign (size_t n, const T &value) |
Assign new contents to the vector, replacing its current contents. More... | |
void | assign (std::initializer_list< T > il) |
Assign new contents to the vector, replacing its current contents. More... | |
T & | at (size_t n) |
const T & | at (size_t n) const |
T & | back () noexcept |
const T & | back () const noexcept |
size_t | capacity () const noexcept |
void | clear () noexcept |
bool | empty () const noexcept |
T & | front () noexcept |
const T & | front () const noexcept |
T * | data () noexcept |
const T * | data () const noexcept |
size_t | max_size () const noexcept |
size_t | size () const noexcept |
void | swap (vector< T, _Alloc > &x) |
Exchange the content of the container by the content of x, which is another object of the same type. More... | |
iterator | begin () noexcept |
const_iterator | begin () const noexcept |
const_iterator | cbegin () const noexcept |
iterator | end () noexcept |
const_iterator | end () const noexcept |
const_iterator | cend () const noexcept |
reverse_iterator | rbegin () noexcept |
const_reverse_iterator | rbegin () const noexcept |
const_reverse_iterator | crbegin () const noexcept |
reverse_iterator | rend () noexcept |
const_reverse_iterator | rend () const noexcept |
const_reverse_iterator | crend () const noexcept |
iterator | erase (const_iterator pos) |
iterator | erase (const_iterator first, const_iterator last) |
std::string | str (int verbosity=1, unsigned int columns=UINT_MAX) const |
Generate a printable representation of the object. More... | |
void | reserve (size_t new_cap) |
void | resize (size_t n) |
Resize the buffer. More... | |
void | resize (size_t n, const T &val) |
Resize the buffer, and assign a value to any new elements if it grows. More... | |
void | shrink_to_fit () |
void | pop_back () |
void | push_back (const T &value) |
void | push_back (T &&value) |
template<class... Args> | |
void | emplace_back (Args &&... args) |
template<class... Args> | |
iterator | emplace (const_iterator pos, Args &&... args) |
Friends | |
void | swap (vector< T, _Alloc > &a, vector< T, _Alloc > &b) |
typedef ConstIterator molpro::vector< T, _Alloc >::const_iterator |
using molpro::vector< T, _Alloc >::const_reverse_iterator = std::reverse_iterator<ConstIterator> |
using molpro::vector< T, _Alloc >::ConstIterator = MyIterator<true> |
using molpro::vector< T, _Alloc >::Iterator = MyIterator<false> |
typedef Iterator molpro::vector< T, _Alloc >::iterator |
using molpro::vector< T, _Alloc >::reverse_iterator = std::reverse_iterator<Iterator> |
|
inline |
Construct a vector of type T with managed storage.
length | The number of elements of buffer. |
|
inline |
Construct a vector of type T with managed storage.
length | The number of elements of buffer. |
value | The value to assign to all elements of the buffer. |
|
inline |
Construct a vector of type T with managed storage.
first | Starting iterator of vector to copy |
last | Ending iterator of vector to copy |
|
inline |
Construct a vector of type T with managed storage.
il | Initializer list |
|
inline |
vector<T> Copy constructor
source | An existing object. An element-by-element copy is made, i.e. the data buffer is allocated then copied from source. |
|
virtualdefault |
|
inline |
Assign new contents to the vector, replacing its current contents.
value | The value to set all elements of the vector to. |
|
inline |
Assign new contents to the vector, replacing its current contents.
first | Starting iterator of vector to copy |
last | Ending iterator of vector to copy |
|
inline |
Assign new contents to the vector, replacing its current contents.
n | The new number of elements |
value | The value to set all elements of the vector to. |
|
inline |
Assign new contents to the vector, replacing its current contents.
il | An initializer. The vector is resized to match the length of il. |
|
inline |
|
inline |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inline |
|
inline |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inline |
|
inline |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inline |
Copy assignment operator.
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inline |
|
inline |
Resize the buffer.
n | New length in bytes. |
|
inline |
Resize the buffer, and assign a value to any new elements if it grows.
n | New length in bytes. |
val | Value to assign to new elements. |
|
inline |
|
inlinenoexcept |
|
inline |
Generate a printable representation of the object.
verbosity | If zero, express only the length of the object; otherwise, its elements. |
columns | If given, a line wrap will be generated every columns values. |
|
inline |
Exchange the content of the container by the content of x, which is another object of the same type.
x | Another vector of the same type. |
|
friend |