| The Gaudi Framework v32r1 (f65d50dc)

Classes | Public Types | Public Member Functions | Private Types | Private Attributes | Static Private Attributes | List of all members
Gaudi::Functional::details::vector_of_const_< Container > Class Template Reference

`#include <GaudiAlg/FunctionalDetails.h>`

Collaboration diagram for Gaudi::Functional::details::vector_of_const_< Container >:
[legend]

## Classes
class | iterator

## Public Types
using | value_type = std::conditional_t< is_pointer, ptr_t, val_t >
using | size_type = typename ContainerVector::size_type

## Public Member Functions
| vector_of_const_ ()=default
void | reserve (size_type size)
template<typename T >
void | push_back (T &&container)
iterator | begin () const
iterator | end () const
size_type | size () const
template<typename X = Container>
std::enable_if_t<!std::is_pointer_v< X >, ref_t > | operator[] (size_type i) const
template<typename X = Container>
std::enable_if_t< std::is_pointer_v< X >, ptr_t > | operator[] (size_type i) const
template<typename X = Container>
std::enable_if_t<!std::is_pointer_v< X >, ref_t > | at (size_type i) const
template<typename X = Container>
std::enable_if_t< std::is_pointer_v< X >, ptr_t > | at (size_type i) const
bool | is_null (size_type i) const

## Private Types
using | val_t = std::add_const_t< std::remove_pointer_t< Container > >
using | ptr_t = std::add_pointer_t< val_t >
using | ref_t = std::add_lvalue_reference_t< val_t >
using | ContainerVector = std::vector< ptr_t >

## Private Attributes
ContainerVector | m_containers

## Static Private Attributes
static constexpr bool | is_pointer = std::is_pointer_v<Container>

## Detailed Description

### template<typename Container>
class Gaudi::Functional::details::vector_of_const_< Container >

Definition at line 216 of file FunctionalDetails.h.

## Member Typedef Documentation

## ◆ ContainerVector

template<typename Container>

using Gaudi::Functional::details::vector_of_const_< Container >::ContainerVector = std::vector<ptr_t>
| private

Definition at line 221 of file FunctionalDetails.h.

## ◆ ptr_t

template<typename Container>

using Gaudi::Functional::details::vector_of_const_< Container >::ptr_t = std::add_pointer_t<val_t>
| private

Definition at line 219 of file FunctionalDetails.h.

## ◆ ref_t

template<typename Container>

using Gaudi::Functional::details::vector_of_const_< Container >::ref_t = std::add_lvalue_reference_t<val_t>
| private

Definition at line 220 of file FunctionalDetails.h.

## ◆ size_type

template<typename Container>

using Gaudi::Functional::details::vector_of_const_< Container >::size_type = typename ContainerVector::size_type

Definition at line 226 of file FunctionalDetails.h.

## ◆ val_t

template<typename Container>

using Gaudi::Functional::details::vector_of_const_< Container >::val_t = std::add_const_t<std::remove_pointer_t<Container> >
| private

Definition at line 218 of file FunctionalDetails.h.

## ◆ value_type

template<typename Container>

using Gaudi::Functional::details::vector_of_const_< Container >::value_type = std::conditional_t<is_pointer, ptr_t, val_t>

Definition at line 225 of file FunctionalDetails.h.

## Constructor & Destructor Documentation

## ◆ vector_of_const_()

template<typename Container>

Gaudi::Functional::details::vector_of_const_< Container >::vector_of_const_ | ( |  | ) |
| default

## Member Function Documentation

## ◆ at() [1/2]

template<typename Container>
template<typename X = Container>

std::enable_if_t<!std::is_pointer_v<X>, ref_t> Gaudi::Functional::details::vector_of_const_< Container >::at | ( | size_type | i | ) | const
| inline

Definition at line 277 of file FunctionalDetails.h.

277 {
278 return *m_containers[i];
279 }
Gaudi::Functional::details::vector_of_const_::m_containers
ContainerVector m_containers
Definition: FunctionalDetails.h:222

## ◆ at() [2/2]

template<typename Container>
template<typename X = Container>

std::enable_if_t<std::is_pointer_v<X>, ptr_t> Gaudi::Functional::details::vector_of_const_< Container >::at | ( | size_type | i | ) | const
| inline

Definition at line 282 of file FunctionalDetails.h.

282 {
283 return m_containers[i];
284 }
Gaudi::Functional::details::vector_of_const_::m_containers
ContainerVector m_containers
Definition: FunctionalDetails.h:222

## ◆ begin()

template<typename Container>

iterator Gaudi::Functional::details::vector_of_const_< Container >::begin | ( |  | ) | const
| inline

Definition at line 262 of file FunctionalDetails.h.

262 { return m_containers.begin(); }
Gaudi::Functional::details::vector_of_const_::m_containers
ContainerVector m_containers
Definition: FunctionalDetails.h:222
std::vector::begin
T begin(T... args)

## ◆ end()

template<typename Container>

iterator Gaudi::Functional::details::vector_of_const_< Container >::end | ( |  | ) | const
| inline

Definition at line 263 of file FunctionalDetails.h.

263 { return m_containers.end(); }
std::vector::end
T end(T... args)
Gaudi::Functional::details::vector_of_const_::m_containers
ContainerVector m_containers
Definition: FunctionalDetails.h:222

## ◆ is_null()

template<typename Container>

bool Gaudi::Functional::details::vector_of_const_< Container >::is_null | ( | size_type | i | ) | const
| inline

Definition at line 286 of file FunctionalDetails.h.

286 { return !m_containers[i]; }
Gaudi::Functional::details::vector_of_const_::m_containers
ContainerVector m_containers
Definition: FunctionalDetails.h:222

## ◆ operator[]() [1/2]

template<typename Container>
template<typename X = Container>

std::enable_if_t<!std::is_pointer_v<X>, ref_t> Gaudi::Functional::details::vector_of_const_< Container >::operator[] | ( | size_type | i | ) | const
| inline

Definition at line 267 of file FunctionalDetails.h.

267 {
268 return *m_containers[i];
269 }
Gaudi::Functional::details::vector_of_const_::m_containers
ContainerVector m_containers
Definition: FunctionalDetails.h:222

## ◆ operator[]() [2/2]

template<typename Container>
template<typename X = Container>

std::enable_if_t<std::is_pointer_v<X>, ptr_t> Gaudi::Functional::details::vector_of_const_< Container >::operator[] | ( | size_type | i | ) | const
| inline

Definition at line 272 of file FunctionalDetails.h.

272 {
273 return m_containers[i];
274 }
Gaudi::Functional::details::vector_of_const_::m_containers
ContainerVector m_containers
Definition: FunctionalDetails.h:222

## ◆ push_back()

template<typename Container>
template<typename T >

void Gaudi::Functional::details::vector_of_const_< Container >::push_back | ( | T && | container | ) |
| inline

Definition at line 259 of file FunctionalDetails.h.

259 {
260 details2::push_back( m_containers, std::forward<T>( container ), std::bool_constant<is_pointer>{} );
261 } // note: does not copy its argument, so we're not really a container...
Gaudi::Functional::details::details2::push_back
void push_back(Container &c, const Value &v, std::true_type)
Definition: FunctionalDetails.h:184
Gaudi::Functional::details::vector_of_const_::m_containers
ContainerVector m_containers
Definition: FunctionalDetails.h:222

## ◆ reserve()

template<typename Container>

void Gaudi::Functional::details::vector_of_const_< Container >::reserve | ( | size_type | size | ) |
| inline

Definition at line 257 of file FunctionalDetails.h.

257 { m_containers.reserve( size ); }
Gaudi::Functional::details::vector_of_const_::m_containers
ContainerVector m_containers
Definition: FunctionalDetails.h:222
Gaudi::Functional::details::vector_of_const_::size
size_type size() const
Definition: FunctionalDetails.h:264
std::vector::reserve
T reserve(T... args)

## ◆ size()

template<typename Container>

size_type Gaudi::Functional::details::vector_of_const_< Container >::size | ( |  | ) | const
| inline

Definition at line 264 of file FunctionalDetails.h.

264 { return m_containers.size(); }
Gaudi::Functional::details::vector_of_const_::m_containers
ContainerVector m_containers
Definition: FunctionalDetails.h:222
std::vector::size
T size(T... args)

## Member Data Documentation

## ◆ is_pointer

template<typename Container>

constexpr bool Gaudi::Functional::details::vector_of_const_< Container >::is_pointer = std::is_pointer_v<Container>
| static private

Definition at line 217 of file FunctionalDetails.h.

## ◆ m_containers

template<typename Container>

ContainerVector Gaudi::Functional::details::vector_of_const_< Container >::m_containers
| private

Definition at line 222 of file FunctionalDetails.h.

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

- GaudiAlg/GaudiAlg/FunctionalDetails.h