Classes | Public Types | Public Member Functions | Static Public Attributes | Private Types | Static Private Member Functions | Private Attributes | Static Private Attributes | Friends | List of all members
absl::FixedArray< T, N, A > Class Template Reference

#include <fixed_array.h>

Classes

struct  EmptyInlinedStorage
 
struct  NonEmptyInlinedStorage
 
class  Storage
 
struct  StorageElementWrapper
 

Public Types

using allocator_type = typename AllocatorTraits::allocator_type
 
using const_iterator = const_pointer
 
using const_pointer = typename allocator_type::const_pointer
 
using const_reference = typename allocator_type::const_reference
 
using const_reverse_iterator = std::reverse_iterator< const_iterator >
 
using difference_type = typename allocator_type::difference_type
 
using iterator = pointer
 
using pointer = typename allocator_type::pointer
 
using reference = typename allocator_type::reference
 
using reverse_iterator = std::reverse_iterator< iterator >
 
using size_type = typename allocator_type::size_type
 
using value_type = typename allocator_type::value_type
 

Public Member Functions

reference at (size_type i)
 
const_reference at (size_type i) const
 
reference back ()
 
const_reference back () const
 
iterator begin ()
 
const_iterator begin () const
 
const_iterator cbegin () const
 
const_iterator cend () const
 
const_reverse_iterator crbegin () const
 
const_reverse_iterator crend () const
 
const_pointer data () const
 
pointer data ()
 
bool empty () const
 
iterator end ()
 
const_iterator end () const
 
void fill (const value_type &val)
 
 FixedArray (const FixedArray &other, const allocator_type &a=allocator_type()) noexcept(NoexceptCopyable())
 
 FixedArray (FixedArray &&other, const allocator_type &a=allocator_type()) noexcept(NoexceptMovable())
 
 FixedArray (size_type n, const allocator_type &a=allocator_type())
 
 FixedArray (size_type n, const value_type &val, const allocator_type &a=allocator_type())
 
 FixedArray (std::initializer_list< value_type > init_list, const allocator_type &a=allocator_type())
 
template<typename Iterator , EnableIfForwardIterator< Iterator > * = nullptr>
 FixedArray (Iterator first, Iterator last, const allocator_type &a=allocator_type())
 
reference front ()
 
const_reference front () const
 
constexpr size_type max_size () const
 
size_t memsize () const
 
void operator= (FixedArray &&)=delete
 
void operator= (const FixedArray &)=delete
 
reference operator[] (size_type i)
 
const_reference operator[] (size_type i) const
 
reverse_iterator rbegin ()
 
const_reverse_iterator rbegin () const
 
reverse_iterator rend ()
 
const_reverse_iterator rend () const
 
size_type size () const
 
 ~FixedArray () noexcept
 

Static Public Attributes

static constexpr size_type inline_elements
 

Private Types

using AllocatorTraits = std::allocator_traits< A >
 
template<typename Iterator >
using EnableIfForwardIterator = absl::enable_if_t< std::is_convertible< typename std::iterator_traits< Iterator >::iterator_category, std::forward_iterator_tag >::value >
 
using InlinedStorage = absl::conditional_t< inline_elements==0, EmptyInlinedStorage, NonEmptyInlinedStorage >
 
using StorageElement = absl::conditional_t< std::is_array< value_type >::value, StorageElementWrapper< value_type >, value_type >
 
using StorageElementBuffer = absl::aligned_storage_t< sizeof(StorageElement), alignof(StorageElement)>
 

Static Private Member Functions

static pointer AsValueType (pointer ptr)
 
static pointer AsValueType (StorageElementWrapper< value_type > *ptr)
 
static constexpr bool DefaultConstructorIsNonTrivial ()
 
static constexpr bool NoexceptCopyable ()
 
static constexpr bool NoexceptMovable ()
 

Private Attributes

Storage storage_
 

Static Private Attributes

static constexpr size_t kInlineBytesDefault = 256
 

Friends

template<typename H >
AbslHashValue (H h, const FixedArray &v)
 
bool operator!= (const FixedArray &lhs, const FixedArray &rhs)
 
bool operator< (const FixedArray &lhs, const FixedArray &rhs)
 
bool operator<= (const FixedArray &lhs, const FixedArray &rhs)
 
bool operator== (const FixedArray &lhs, const FixedArray &rhs)
 
bool operator> (const FixedArray &lhs, const FixedArray &rhs)
 
bool operator>= (const FixedArray &lhs, const FixedArray &rhs)
 

Detailed Description

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
class absl::FixedArray< T, N, A >

Definition at line 82 of file fixed_array.h.

Member Typedef Documentation

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
using absl::FixedArray< T, N, A >::allocator_type = typename AllocatorTraits::allocator_type

Definition at line 108 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
using absl::FixedArray< T, N, A >::AllocatorTraits = std::allocator_traits<A>
private

Definition at line 88 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
using absl::FixedArray< T, N, A >::const_iterator = const_pointer

Definition at line 117 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
using absl::FixedArray< T, N, A >::const_pointer = typename allocator_type::const_pointer

Definition at line 111 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
using absl::FixedArray< T, N, A >::const_reference = typename allocator_type::const_reference

Definition at line 113 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
using absl::FixedArray< T, N, A >::const_reverse_iterator = std::reverse_iterator<const_iterator>

Definition at line 119 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
using absl::FixedArray< T, N, A >::difference_type = typename allocator_type::difference_type

Definition at line 115 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
template<typename Iterator >
using absl::FixedArray< T, N, A >::EnableIfForwardIterator = absl::enable_if_t<std::is_convertible< typename std::iterator_traits<Iterator>::iterator_category, std::forward_iterator_tag>::value>
private

Definition at line 94 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
using absl::FixedArray< T, N, A >::InlinedStorage = absl::conditional_t<inline_elements == 0, EmptyInlinedStorage, NonEmptyInlinedStorage>
private

Definition at line 436 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
using absl::FixedArray< T, N, A >::iterator = pointer

Definition at line 116 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
using absl::FixedArray< T, N, A >::pointer = typename allocator_type::pointer

Definition at line 110 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
using absl::FixedArray< T, N, A >::reference = typename allocator_type::reference

Definition at line 112 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
using absl::FixedArray< T, N, A >::reverse_iterator = std::reverse_iterator<iterator>

Definition at line 118 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
using absl::FixedArray< T, N, A >::size_type = typename allocator_type::size_type

Definition at line 114 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
using absl::FixedArray< T, N, A >::StorageElement = absl::conditional_t<std::is_array<value_type>::value, StorageElementWrapper<value_type>, value_type>
private

Definition at line 398 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
using absl::FixedArray< T, N, A >::StorageElementBuffer = absl::aligned_storage_t<sizeof(StorageElement), alignof(StorageElement)>
private

Definition at line 400 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
using absl::FixedArray< T, N, A >::value_type = typename allocator_type::value_type

Definition at line 109 of file fixed_array.h.

Constructor & Destructor Documentation

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
absl::FixedArray< T, N, A >::FixedArray ( const FixedArray< T, N, A > &  other,
const allocator_type a = allocator_type() 
)
inlinenoexcept

Definition at line 125 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
absl::FixedArray< T, N, A >::FixedArray ( FixedArray< T, N, A > &&  other,
const allocator_type a = allocator_type() 
)
inlinenoexcept

Definition at line 130 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
absl::FixedArray< T, N, A >::FixedArray ( size_type  n,
const allocator_type a = allocator_type() 
)
inlineexplicit

Definition at line 138 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
absl::FixedArray< T, N, A >::FixedArray ( size_type  n,
const value_type val,
const allocator_type a = allocator_type() 
)
inline

Definition at line 147 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
absl::FixedArray< T, N, A >::FixedArray ( std::initializer_list< value_type init_list,
const allocator_type a = allocator_type() 
)
inline

Definition at line 155 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
template<typename Iterator , EnableIfForwardIterator< Iterator > * = nullptr>
absl::FixedArray< T, N, A >::FixedArray ( Iterator  first,
Iterator  last,
const allocator_type a = allocator_type() 
)
inline

Definition at line 163 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
absl::FixedArray< T, N, A >::~FixedArray ( )
inlinenoexcept

Definition at line 169 of file fixed_array.h.

Member Function Documentation

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
static pointer absl::FixedArray< T, N, A >::AsValueType ( pointer  ptr)
inlinestaticprivate

Definition at line 402 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
static pointer absl::FixedArray< T, N, A >::AsValueType ( StorageElementWrapper< value_type > *  ptr)
inlinestaticprivate

Definition at line 403 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
reference absl::FixedArray< T, N, A >::at ( size_type  i)
inline

Definition at line 236 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
const_reference absl::FixedArray< T, N, A >::at ( size_type  i) const
inline

Definition at line 245 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
reference absl::FixedArray< T, N, A >::back ( )
inline

Definition at line 264 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
const_reference absl::FixedArray< T, N, A >::back ( ) const
inline

Definition at line 268 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
iterator absl::FixedArray< T, N, A >::begin ( )
inline

Definition at line 273 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
const_iterator absl::FixedArray< T, N, A >::begin ( ) const
inline

Definition at line 277 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
const_iterator absl::FixedArray< T, N, A >::cbegin ( ) const
inline

Definition at line 282 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
const_iterator absl::FixedArray< T, N, A >::cend ( ) const
inline

Definition at line 296 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
const_reverse_iterator absl::FixedArray< T, N, A >::crbegin ( ) const
inline

Definition at line 312 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
const_reverse_iterator absl::FixedArray< T, N, A >::crend ( ) const
inline

Definition at line 328 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
const_pointer absl::FixedArray< T, N, A >::data ( ) const
inline

Definition at line 208 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
pointer absl::FixedArray< T, N, A >::data ( )
inline

Definition at line 213 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
static constexpr bool absl::FixedArray< T, N, A >::DefaultConstructorIsNonTrivial ( )
inlinestaticprivate

Definition at line 103 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
bool absl::FixedArray< T, N, A >::empty ( ) const
inline

Definition at line 197 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
iterator absl::FixedArray< T, N, A >::end ( )
inline

Definition at line 287 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
const_iterator absl::FixedArray< T, N, A >::end ( ) const
inline

Definition at line 291 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
void absl::FixedArray< T, N, A >::fill ( const value_type val)
inline

Definition at line 333 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
reference absl::FixedArray< T, N, A >::front ( )
inline

Definition at line 255 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
const_reference absl::FixedArray< T, N, A >::front ( ) const
inline

Definition at line 259 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
constexpr size_type absl::FixedArray< T, N, A >::max_size ( ) const
inline

Definition at line 190 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
size_t absl::FixedArray< T, N, A >::memsize ( ) const
inline

Definition at line 202 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
static constexpr bool absl::FixedArray< T, N, A >::NoexceptCopyable ( )
inlinestaticprivate

Definition at line 95 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
static constexpr bool absl::FixedArray< T, N, A >::NoexceptMovable ( )
inlinestaticprivate

Definition at line 99 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
void absl::FixedArray< T, N, A >::operator= ( FixedArray< T, N, A > &&  )
delete
template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
void absl::FixedArray< T, N, A >::operator= ( const FixedArray< T, N, A > &  )
delete
template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
reference absl::FixedArray< T, N, A >::operator[] ( size_type  i)
inline

Definition at line 219 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
const_reference absl::FixedArray< T, N, A >::operator[] ( size_type  i) const
inline

Definition at line 227 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
reverse_iterator absl::FixedArray< T, N, A >::rbegin ( )
inline

Definition at line 301 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
const_reverse_iterator absl::FixedArray< T, N, A >::rbegin ( ) const
inline

Definition at line 305 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
reverse_iterator absl::FixedArray< T, N, A >::rend ( )
inline

Definition at line 317 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
const_reverse_iterator absl::FixedArray< T, N, A >::rend ( ) const
inline

Definition at line 321 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
size_type absl::FixedArray< T, N, A >::size ( ) const
inline

Definition at line 183 of file fixed_array.h.

Friends And Related Function Documentation

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
template<typename H >
H AbslHashValue ( h,
const FixedArray< T, N, A > &  v 
)
friend

Definition at line 363 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
bool operator!= ( const FixedArray< T, N, A > &  lhs,
const FixedArray< T, N, A > &  rhs 
)
friend

Definition at line 341 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
bool operator< ( const FixedArray< T, N, A > &  lhs,
const FixedArray< T, N, A > &  rhs 
)
friend

Definition at line 345 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
bool operator<= ( const FixedArray< T, N, A > &  lhs,
const FixedArray< T, N, A > &  rhs 
)
friend

Definition at line 354 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
bool operator== ( const FixedArray< T, N, A > &  lhs,
const FixedArray< T, N, A > &  rhs 
)
friend

Definition at line 337 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
bool operator> ( const FixedArray< T, N, A > &  lhs,
const FixedArray< T, N, A > &  rhs 
)
friend

Definition at line 350 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
bool operator>= ( const FixedArray< T, N, A > &  lhs,
const FixedArray< T, N, A > &  rhs 
)
friend

Definition at line 358 of file fixed_array.h.

Member Data Documentation

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
constexpr FixedArray< T, N, A >::size_type absl::FixedArray< T, N, A >::inline_elements
static
Initial value:
=
: static_cast<size_type>(N))

Definition at line 121 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
constexpr size_t absl::FixedArray< T, N, A >::kInlineBytesDefault = 256
staticprivate

Definition at line 86 of file fixed_array.h.

template<typename T, size_t N = kFixedArrayUseDefault, typename A = std::allocator<T>>
Storage absl::FixedArray< T, N, A >::storage_
private

Definition at line 486 of file fixed_array.h.


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


abseil_cpp
Author(s):
autogenerated on Wed Jun 19 2019 19:19:59