NSVD Reader  0.0.1
nodamushi::boxvec< T, PTR > Class Template Reference

vector<pointer<T>>. More...

#include <boxvec.hpp>

Public Types

using box = PTR
 
using vec_t = std::vector< PTR >
 
using iterator = boxitr< T, typename vec_t::iterator >
 
using const_iterator = boxitr< const T, typename vec_t::const_iterator >
 
using size_type = typename vec_t::size_type
 
using reference = T &
 
using const_reference = const T &
 
using value_type = T
 
using reverse_iterator = boxitr< T, typename vec_t::reverse_iterator >
 
using const_reverse_iterator = boxitr< const T, typename vec_t::const_reverse_iterator >
 

Public Member Functions

 boxvec ()
 
 boxvec (size_type initial_capacity)
 
 boxvec (const boxvec< T, PTR > &src)
 deap copy More...
 
boxvec< T, PTR > & operator= (const boxvec< T, PTR > &src)
 deap copy More...
 
template<typename P >
 boxvec (boxvec< T, P > &&src)
 
template<typename P >
boxvec< T, PTR > & operator= (boxvec< T, P > &&src)
 
template<typename P >
void add_all (const boxvec< T, P > &src)
 
template<typename P >
void add_all (boxvec< T, P > &&src)
 
 operator bool () const noexcept
 
size_type size () const noexcept
 
size_type max_size () const noexcept
 
size_type capacity () const noexcept
 
bool empty () const noexcept
 
void reserve (size_type n)
 
void shurink_to_fit ()
 
reference operator[] (size_type n)
 
const_reference operator[] (size_type n) const
 
reference at (size_type n)
 
const_reference at (size_type n) const
 
PTR ptr_at (size_type n)
 
const PTR ptr_at (size_type n) const
 
reference front ()
 
const_reference front () const
 
reference back ()
 
const_reference back () const
 
template<class InputIterator >
void assign (InputIterator first, InputIterator last)
 
void push_back (const T &t)
 
void push_back (T &&t)
 
void push_back (box &&t)
 
void push_back (const box &t)
 
template<typename... ARGS>
void emplace_back (ARGS &&... args)
 
template<class... ARGS>
iterator emplace (const_iterator position, ARGS &&... args)
 
void pop_back ()
 
iterator insert (iterator position, const T &x)
 
iterator insert (const_iterator position, const T &x)
 
iterator insert (const_iterator position, T &&x)
 
template<class InputIterator >
iterator insert (iterator position, InputIterator first, InputIterator last)
 
iterator erase (iterator position)
 
iterator erase (const_iterator position)
 
iterator erase (iterator first, iterator last)
 
iterator erase (const_iterator first, const_iterator last)
 
void swap (boxvec< T, PTR > &x)
 
void clear ()
 
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
 
vec_t::iterator ptr_begin () noexcept
 
vec_t::const_iterator ptr_begin () const noexcept
 
vec_t::iterator ptr_end () noexcept
 
vec_t::const_iterator ptr_end () const noexcept
 
reverse_iterator rbegin () noexcept
 
reverse_iterator rend () noexcept
 
const_reverse_iterator rbegin () const noexcept
 
const_reverse_iterator rend () const noexcept
 
const_reverse_iterator crbegin () const noexcept
 
const_reverse_iterator crend () const noexcept
 
void sort (std::function< bool(const T &, const T &)> comp)
 sort elements More...
 
template<bool Compare>
void sort ()
 sort elements More...
 

Detailed Description

template<typename T, typename PTR = ::nodamushi::box<T>>
class nodamushi::boxvec< T, PTR >

vector<pointer<T>>.

This list contains pointer eleent. but , boxvec[x] return reference.
boxvec<T> vector;
.....
T& v = vector[0];

Definition at line 75 of file boxvec.hpp.

Member Typedef Documentation

◆ box

template<typename T, typename PTR = ::nodamushi::box<T>>
using nodamushi::boxvec< T, PTR >::box = PTR

Definition at line 78 of file boxvec.hpp.

◆ const_iterator

template<typename T, typename PTR = ::nodamushi::box<T>>
using nodamushi::boxvec< T, PTR >::const_iterator = boxitr<const T,typename vec_t::const_iterator>

Definition at line 82 of file boxvec.hpp.

◆ const_reference

template<typename T, typename PTR = ::nodamushi::box<T>>
using nodamushi::boxvec< T, PTR >::const_reference = const T&

Definition at line 85 of file boxvec.hpp.

◆ const_reverse_iterator

template<typename T, typename PTR = ::nodamushi::box<T>>
using nodamushi::boxvec< T, PTR >::const_reverse_iterator = boxitr<const T,typename vec_t::const_reverse_iterator>

Definition at line 88 of file boxvec.hpp.

◆ iterator

template<typename T, typename PTR = ::nodamushi::box<T>>
using nodamushi::boxvec< T, PTR >::iterator = boxitr<T,typename vec_t::iterator>

Definition at line 81 of file boxvec.hpp.

◆ reference

template<typename T, typename PTR = ::nodamushi::box<T>>
using nodamushi::boxvec< T, PTR >::reference = T&

Definition at line 84 of file boxvec.hpp.

◆ reverse_iterator

template<typename T, typename PTR = ::nodamushi::box<T>>
using nodamushi::boxvec< T, PTR >::reverse_iterator = boxitr<T,typename vec_t::reverse_iterator>

Definition at line 87 of file boxvec.hpp.

◆ size_type

template<typename T, typename PTR = ::nodamushi::box<T>>
using nodamushi::boxvec< T, PTR >::size_type = typename vec_t::size_type

Definition at line 83 of file boxvec.hpp.

◆ value_type

template<typename T, typename PTR = ::nodamushi::box<T>>
using nodamushi::boxvec< T, PTR >::value_type = T

Definition at line 86 of file boxvec.hpp.

◆ vec_t

template<typename T, typename PTR = ::nodamushi::box<T>>
using nodamushi::boxvec< T, PTR >::vec_t = std::vector<PTR>

Definition at line 79 of file boxvec.hpp.

Constructor & Destructor Documentation

◆ boxvec() [1/4]

template<typename T, typename PTR = ::nodamushi::box<T>>
nodamushi::boxvec< T, PTR >::boxvec ( )
inline

Definition at line 90 of file boxvec.hpp.

◆ boxvec() [2/4]

template<typename T, typename PTR = ::nodamushi::box<T>>
nodamushi::boxvec< T, PTR >::boxvec ( size_type  initial_capacity)
inline

Definition at line 91 of file boxvec.hpp.

◆ boxvec() [3/4]

template<typename T, typename PTR = ::nodamushi::box<T>>
nodamushi::boxvec< T, PTR >::boxvec ( const boxvec< T, PTR > &  src)
inline

deap copy

Definition at line 99 of file boxvec.hpp.

◆ boxvec() [4/4]

template<typename T, typename PTR = ::nodamushi::box<T>>
template<typename P >
nodamushi::boxvec< T, PTR >::boxvec ( boxvec< T, P > &&  src)
inline

Definition at line 116 of file boxvec.hpp.

Member Function Documentation

◆ add_all() [1/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
template<typename P >
void nodamushi::boxvec< T, PTR >::add_all ( const boxvec< T, P > &  src)
inline

Definition at line 122 of file boxvec.hpp.

◆ add_all() [2/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
template<typename P >
void nodamushi::boxvec< T, PTR >::add_all ( boxvec< T, P > &&  src)
inline

Definition at line 129 of file boxvec.hpp.

◆ assign()

template<typename T, typename PTR = ::nodamushi::box<T>>
template<class InputIterator >
void nodamushi::boxvec< T, PTR >::assign ( InputIterator  first,
InputIterator  last 
)
inline

Definition at line 160 of file boxvec.hpp.

◆ at() [1/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
reference nodamushi::boxvec< T, PTR >::at ( size_type  n)
inline

Definition at line 147 of file boxvec.hpp.

◆ at() [2/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
const_reference nodamushi::boxvec< T, PTR >::at ( size_type  n) const
inline

Definition at line 148 of file boxvec.hpp.

◆ back() [1/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
reference nodamushi::boxvec< T, PTR >::back ( )
inline

Definition at line 156 of file boxvec.hpp.

◆ back() [2/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
const_reference nodamushi::boxvec< T, PTR >::back ( ) const
inline

Definition at line 157 of file boxvec.hpp.

◆ begin() [1/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
iterator nodamushi::boxvec< T, PTR >::begin ( )
inlinenoexcept

Definition at line 236 of file boxvec.hpp.

◆ begin() [2/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
const_iterator nodamushi::boxvec< T, PTR >::begin ( ) const
inlinenoexcept

Definition at line 237 of file boxvec.hpp.

◆ capacity()

template<typename T, typename PTR = ::nodamushi::box<T>>
size_type nodamushi::boxvec< T, PTR >::capacity ( ) const
inlinenoexcept

Definition at line 139 of file boxvec.hpp.

◆ cbegin()

template<typename T, typename PTR = ::nodamushi::box<T>>
const_iterator nodamushi::boxvec< T, PTR >::cbegin ( ) const
inlinenoexcept

Definition at line 238 of file boxvec.hpp.

◆ cend()

template<typename T, typename PTR = ::nodamushi::box<T>>
const_iterator nodamushi::boxvec< T, PTR >::cend ( ) const
inlinenoexcept

Definition at line 241 of file boxvec.hpp.

◆ clear()

template<typename T, typename PTR = ::nodamushi::box<T>>
void nodamushi::boxvec< T, PTR >::clear ( )
inline

Definition at line 232 of file boxvec.hpp.

◆ crbegin()

template<typename T, typename PTR = ::nodamushi::box<T>>
const_reverse_iterator nodamushi::boxvec< T, PTR >::crbegin ( ) const
inlinenoexcept

Definition at line 252 of file boxvec.hpp.

◆ crend()

template<typename T, typename PTR = ::nodamushi::box<T>>
const_reverse_iterator nodamushi::boxvec< T, PTR >::crend ( ) const
inlinenoexcept

Definition at line 253 of file boxvec.hpp.

◆ emplace()

template<typename T, typename PTR = ::nodamushi::box<T>>
template<class... ARGS>
iterator nodamushi::boxvec< T, PTR >::emplace ( const_iterator  position,
ARGS &&...  args 
)
inline

Definition at line 192 of file boxvec.hpp.

◆ emplace_back()

template<typename T, typename PTR = ::nodamushi::box<T>>
template<typename... ARGS>
void nodamushi::boxvec< T, PTR >::emplace_back ( ARGS &&...  args)
inline

Definition at line 187 of file boxvec.hpp.

◆ empty()

template<typename T, typename PTR = ::nodamushi::box<T>>
bool nodamushi::boxvec< T, PTR >::empty ( ) const
inlinenoexcept

Definition at line 140 of file boxvec.hpp.

◆ end() [1/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
iterator nodamushi::boxvec< T, PTR >::end ( )
inlinenoexcept

Definition at line 239 of file boxvec.hpp.

◆ end() [2/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
const_iterator nodamushi::boxvec< T, PTR >::end ( ) const
inlinenoexcept

Definition at line 240 of file boxvec.hpp.

◆ erase() [1/4]

template<typename T, typename PTR = ::nodamushi::box<T>>
iterator nodamushi::boxvec< T, PTR >::erase ( iterator  position)
inline

Definition at line 224 of file boxvec.hpp.

◆ erase() [2/4]

template<typename T, typename PTR = ::nodamushi::box<T>>
iterator nodamushi::boxvec< T, PTR >::erase ( const_iterator  position)
inline

Definition at line 225 of file boxvec.hpp.

◆ erase() [3/4]

template<typename T, typename PTR = ::nodamushi::box<T>>
iterator nodamushi::boxvec< T, PTR >::erase ( iterator  first,
iterator  last 
)
inline

Definition at line 226 of file boxvec.hpp.

◆ erase() [4/4]

template<typename T, typename PTR = ::nodamushi::box<T>>
iterator nodamushi::boxvec< T, PTR >::erase ( const_iterator  first,
const_iterator  last 
)
inline

Definition at line 227 of file boxvec.hpp.

◆ front() [1/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
reference nodamushi::boxvec< T, PTR >::front ( )
inline

Definition at line 153 of file boxvec.hpp.

◆ front() [2/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
const_reference nodamushi::boxvec< T, PTR >::front ( ) const
inline

Definition at line 154 of file boxvec.hpp.

◆ insert() [1/4]

template<typename T, typename PTR = ::nodamushi::box<T>>
iterator nodamushi::boxvec< T, PTR >::insert ( iterator  position,
const T &  x 
)
inline

Definition at line 199 of file boxvec.hpp.

◆ insert() [2/4]

template<typename T, typename PTR = ::nodamushi::box<T>>
iterator nodamushi::boxvec< T, PTR >::insert ( const_iterator  position,
const T &  x 
)
inline

Definition at line 203 of file boxvec.hpp.

◆ insert() [3/4]

template<typename T, typename PTR = ::nodamushi::box<T>>
iterator nodamushi::boxvec< T, PTR >::insert ( const_iterator  position,
T &&  x 
)
inline

Definition at line 208 of file boxvec.hpp.

◆ insert() [4/4]

template<typename T, typename PTR = ::nodamushi::box<T>>
template<class InputIterator >
iterator nodamushi::boxvec< T, PTR >::insert ( iterator  position,
InputIterator  first,
InputIterator  last 
)
inline

Definition at line 213 of file boxvec.hpp.

◆ max_size()

template<typename T, typename PTR = ::nodamushi::box<T>>
size_type nodamushi::boxvec< T, PTR >::max_size ( ) const
inlinenoexcept

Definition at line 138 of file boxvec.hpp.

◆ operator bool()

template<typename T, typename PTR = ::nodamushi::box<T>>
nodamushi::boxvec< T, PTR >::operator bool ( ) const
inlinenoexcept

Definition at line 135 of file boxvec.hpp.

◆ operator=() [1/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
boxvec<T,PTR>& nodamushi::boxvec< T, PTR >::operator= ( const boxvec< T, PTR > &  src)
inline

deap copy

Definition at line 106 of file boxvec.hpp.

◆ operator=() [2/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
template<typename P >
boxvec<T,PTR>& nodamushi::boxvec< T, PTR >::operator= ( boxvec< T, P > &&  src)
inline

Definition at line 118 of file boxvec.hpp.

◆ operator[]() [1/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
reference nodamushi::boxvec< T, PTR >::operator[] ( size_type  n)
inline

Definition at line 144 of file boxvec.hpp.

◆ operator[]() [2/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
const_reference nodamushi::boxvec< T, PTR >::operator[] ( size_type  n) const
inline

Definition at line 145 of file boxvec.hpp.

◆ pop_back()

template<typename T, typename PTR = ::nodamushi::box<T>>
void nodamushi::boxvec< T, PTR >::pop_back ( )
inline

Definition at line 197 of file boxvec.hpp.

◆ ptr_at() [1/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
PTR nodamushi::boxvec< T, PTR >::ptr_at ( size_type  n)
inline

Definition at line 149 of file boxvec.hpp.

◆ ptr_at() [2/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
const PTR nodamushi::boxvec< T, PTR >::ptr_at ( size_type  n) const
inline

Definition at line 150 of file boxvec.hpp.

◆ ptr_begin() [1/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
vec_t::iterator nodamushi::boxvec< T, PTR >::ptr_begin ( )
inlinenoexcept

Definition at line 243 of file boxvec.hpp.

◆ ptr_begin() [2/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
vec_t::const_iterator nodamushi::boxvec< T, PTR >::ptr_begin ( ) const
inlinenoexcept

Definition at line 244 of file boxvec.hpp.

◆ ptr_end() [1/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
vec_t::iterator nodamushi::boxvec< T, PTR >::ptr_end ( )
inlinenoexcept

Definition at line 245 of file boxvec.hpp.

◆ ptr_end() [2/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
vec_t::const_iterator nodamushi::boxvec< T, PTR >::ptr_end ( ) const
inlinenoexcept

Definition at line 246 of file boxvec.hpp.

◆ push_back() [1/4]

template<typename T, typename PTR = ::nodamushi::box<T>>
void nodamushi::boxvec< T, PTR >::push_back ( const T &  t)
inline

Definition at line 168 of file boxvec.hpp.

◆ push_back() [2/4]

template<typename T, typename PTR = ::nodamushi::box<T>>
void nodamushi::boxvec< T, PTR >::push_back ( T &&  t)
inline

Definition at line 172 of file boxvec.hpp.

◆ push_back() [3/4]

template<typename T, typename PTR = ::nodamushi::box<T>>
void nodamushi::boxvec< T, PTR >::push_back ( box &&  t)
inline

Definition at line 176 of file boxvec.hpp.

◆ push_back() [4/4]

template<typename T, typename PTR = ::nodamushi::box<T>>
void nodamushi::boxvec< T, PTR >::push_back ( const box t)
inline

Definition at line 181 of file boxvec.hpp.

◆ rbegin() [1/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
reverse_iterator nodamushi::boxvec< T, PTR >::rbegin ( )
inlinenoexcept

Definition at line 248 of file boxvec.hpp.

◆ rbegin() [2/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
const_reverse_iterator nodamushi::boxvec< T, PTR >::rbegin ( ) const
inlinenoexcept

Definition at line 250 of file boxvec.hpp.

◆ rend() [1/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
reverse_iterator nodamushi::boxvec< T, PTR >::rend ( )
inlinenoexcept

Definition at line 249 of file boxvec.hpp.

◆ rend() [2/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
const_reverse_iterator nodamushi::boxvec< T, PTR >::rend ( ) const
inlinenoexcept

Definition at line 251 of file boxvec.hpp.

◆ reserve()

template<typename T, typename PTR = ::nodamushi::box<T>>
void nodamushi::boxvec< T, PTR >::reserve ( size_type  n)
inline

Definition at line 141 of file boxvec.hpp.

◆ shurink_to_fit()

template<typename T, typename PTR = ::nodamushi::box<T>>
void nodamushi::boxvec< T, PTR >::shurink_to_fit ( )
inline

Definition at line 142 of file boxvec.hpp.

◆ size()

template<typename T, typename PTR = ::nodamushi::box<T>>
size_type nodamushi::boxvec< T, PTR >::size ( ) const
inlinenoexcept

Definition at line 137 of file boxvec.hpp.

◆ sort() [1/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
void nodamushi::boxvec< T, PTR >::sort ( std::function< bool(const T &, const T &)>  comp)
inline

sort elements

Definition at line 256 of file boxvec.hpp.

◆ sort() [2/2]

template<typename T, typename PTR = ::nodamushi::box<T>>
template<bool Compare>
void nodamushi::boxvec< T, PTR >::sort ( )
inline

sort elements

Definition at line 266 of file boxvec.hpp.

◆ swap()

template<typename T, typename PTR = ::nodamushi::box<T>>
void nodamushi::boxvec< T, PTR >::swap ( boxvec< T, PTR > &  x)
inline

Definition at line 231 of file boxvec.hpp.


The documentation for this class was generated from the following file: