Slice< T > Struct Template Reference

AMR-Wind API: amr_wind::utils::Slice< T > Struct Template Reference
AMR-Wind API v0.1.0
CFD solver for wind plant simulations
Loading...
Searching...
No Matches
amr_wind::utils::Slice< T > Struct Template Reference

#include <Slice.H>

Inheritance diagram for amr_wind::utils::Slice< T >:
[legend]

Public Types

using value_type = T
 
using size_t = std::size_t
 
using size_type = std::size_t
 
using difference_type = std::ptrdiff_t
 
using reference = T&
 
using pointer = T*
 
using iterator = T*
 
using reverse_iterator = std::reverse_iterator<iterator>
 
using const_reference = const T&
 
using const_pointer = const T*
 
using const_iterator = const T*
 
using const_reverse_iterator = const std::reverse_iterator<iterator>
 

Public Member Functions

 Slice ()
 
 Slice (T *pbegin, const size_t n)
 
 Slice (T *pbegin, T *pend)
 
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE reference operator[] (const size_t idx)
 
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE const_reference operator[] (const size_type idx) const
 
AMREX_GPU_HOST_DEVICE size_type size () const
 
AMREX_GPU_HOST_DEVICE pointer data ()
 
AMREX_GPU_HOST_DEVICE iterator begin ()
 
AMREX_GPU_HOST_DEVICE iterator end ()
 
AMREX_GPU_HOST_DEVICE const_iterator data () const
 
AMREX_GPU_HOST_DEVICE const_iterator begin () const
 
AMREX_GPU_HOST_DEVICE const_iterator end () const
 
AMREX_GPU_HOST_DEVICE const_iterator cbegin () const
 
AMREX_GPU_HOST_DEVICE const_iterator cend () const
 

Public Attributes

pointer ptr_begin
 
pointer ptr_end
 

Member Typedef Documentation

◆ const_iterator

template<typename T >
using amr_wind::utils::Slice< T >::const_iterator = const T*

◆ const_pointer

template<typename T >
using amr_wind::utils::Slice< T >::const_pointer = const T*

◆ const_reference

template<typename T >
using amr_wind::utils::Slice< T >::const_reference = const T&

◆ const_reverse_iterator

template<typename T >
using amr_wind::utils::Slice< T >::const_reverse_iterator = const std::reverse_iterator<iterator>

◆ difference_type

template<typename T >
using amr_wind::utils::Slice< T >::difference_type = std::ptrdiff_t

◆ iterator

template<typename T >
using amr_wind::utils::Slice< T >::iterator = T*

◆ pointer

template<typename T >
using amr_wind::utils::Slice< T >::pointer = T*

◆ reference

template<typename T >
using amr_wind::utils::Slice< T >::reference = T&

◆ reverse_iterator

template<typename T >
using amr_wind::utils::Slice< T >::reverse_iterator = std::reverse_iterator<iterator>

◆ size_t

template<typename T >
using amr_wind::utils::Slice< T >::size_t = std::size_t

◆ size_type

template<typename T >
using amr_wind::utils::Slice< T >::size_type = std::size_t

◆ value_type

template<typename T >
using amr_wind::utils::Slice< T >::value_type = T

Constructor & Destructor Documentation

◆ Slice() [1/3]

template<typename T >
amr_wind::utils::Slice< T >::Slice ( )
inlineexplicit

◆ Slice() [2/3]

template<typename T >
amr_wind::utils::Slice< T >::Slice ( T * pbegin,
const size_t n )
inlineexplicit

◆ Slice() [3/3]

template<typename T >
amr_wind::utils::Slice< T >::Slice ( T * pbegin,
T * pend )
inlineexplicit

Member Function Documentation

◆ begin() [1/2]

template<typename T >
AMREX_GPU_HOST_DEVICE iterator amr_wind::utils::Slice< T >::begin ( )
inline

◆ begin() [2/2]

template<typename T >
AMREX_GPU_HOST_DEVICE const_iterator amr_wind::utils::Slice< T >::begin ( ) const
inline

◆ cbegin()

template<typename T >
AMREX_GPU_HOST_DEVICE const_iterator amr_wind::utils::Slice< T >::cbegin ( ) const
inline

◆ cend()

template<typename T >
AMREX_GPU_HOST_DEVICE const_iterator amr_wind::utils::Slice< T >::cend ( ) const
inline

◆ data() [1/2]

template<typename T >
AMREX_GPU_HOST_DEVICE pointer amr_wind::utils::Slice< T >::data ( )
inline

◆ data() [2/2]

template<typename T >
AMREX_GPU_HOST_DEVICE const_iterator amr_wind::utils::Slice< T >::data ( ) const
inline

◆ end() [1/2]

template<typename T >
AMREX_GPU_HOST_DEVICE iterator amr_wind::utils::Slice< T >::end ( )
inline

◆ end() [2/2]

template<typename T >
AMREX_GPU_HOST_DEVICE const_iterator amr_wind::utils::Slice< T >::end ( ) const
inline

◆ operator[]() [1/2]

template<typename T >
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE reference amr_wind::utils::Slice< T >::operator[] ( const size_t idx)
inline

◆ operator[]() [2/2]

template<typename T >
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE const_reference amr_wind::utils::Slice< T >::operator[] ( const size_type idx) const
inline

◆ size()

template<typename T >
AMREX_GPU_HOST_DEVICE size_type amr_wind::utils::Slice< T >::size ( ) const
inline

Member Data Documentation

◆ ptr_begin

template<typename T >
pointer amr_wind::utils::Slice< T >::ptr_begin

◆ ptr_end

template<typename T >
pointer amr_wind::utils::Slice< T >::ptr_end

The documentation for this struct was generated from the following file:
  • /home/runner/work/amr-wind/amr-wind/amr-wind/core/Slice.H