NVBIO
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Types | Public Methods | Public Members | List of all members
nvbio::strided_iterator< T > Struct Template Reference

Detailed description

template< typename T>
struct nvbio::strided_iterator< T >

Wrapper class to create a strided iterator out of another base iterator, i.e:

it[ j ] = base[ j * stride ]

Definition at line 60 of file strided_iterator.h.

#include <strided_iterator.h>

Public Types

typedef std::iterator_traits
< T >::value_type 
value_type
 
typedef std::iterator_traits
< T >::reference 
reference
 
typedef to_const< reference >::type const_reference
 
typedef std::iterator_traits
< T >::pointer 
pointer
 
typedef std::iterator_traits
< T >::difference_type 
difference_type
 
typedef std::iterator_traits
< T >::iterator_category 
iterator_category
 

Public Methods

NVBIO_FORCEINLINE NVBIO_HOST_DEVICE strided_iterator ()
 
NVBIO_FORCEINLINE NVBIO_HOST_DEVICE strided_iterator (T vec, const uint32 stride)
 
NVBIO_FORCEINLINE
NVBIO_HOST_DEVICE
const_reference 
operator* () const
 
NVBIO_FORCEINLINE
NVBIO_HOST_DEVICE reference 
operator* ()
 
NVBIO_FORCEINLINE
NVBIO_HOST_DEVICE
const_reference 
operator[] (const uint32 i) const
 
NVBIO_FORCEINLINE
NVBIO_HOST_DEVICE reference 
operator[] (const uint32 i)
 
NVBIO_FORCEINLINE
NVBIO_HOST_DEVICE
strided_iterator< T > 
operator+ (const uint32 i) const
 
NVBIO_FORCEINLINE
NVBIO_HOST_DEVICE
difference_type 
operator- (const strided_iterator< T > it) const
 
NVBIO_FORCEINLINE
NVBIO_HOST_DEVICE
strided_iterator< T > & 
operator++ ()
 

Public Members

m_vec
 
uint32 m_stride
 

Member Typedef Documentation

template<typename T>
typedef to_const<reference>::type nvbio::strided_iterator< T >::const_reference

Definition at line 64 of file strided_iterator.h.

template<typename T>
typedef std::iterator_traits<T>::difference_type nvbio::strided_iterator< T >::difference_type

Definition at line 66 of file strided_iterator.h.

template<typename T>
typedef std::iterator_traits<T>::iterator_category nvbio::strided_iterator< T >::iterator_category

Definition at line 68 of file strided_iterator.h.

template<typename T>
typedef std::iterator_traits<T>::pointer nvbio::strided_iterator< T >::pointer

Definition at line 65 of file strided_iterator.h.

template<typename T>
typedef std::iterator_traits<T>::reference nvbio::strided_iterator< T >::reference

Definition at line 63 of file strided_iterator.h.

template<typename T>
typedef std::iterator_traits<T>::value_type nvbio::strided_iterator< T >::value_type

Definition at line 62 of file strided_iterator.h.

Constructor & Destructor Documentation

constructor

Definition at line 73 of file strided_iterator.h.

template<typename T>
NVBIO_FORCEINLINE NVBIO_HOST_DEVICE nvbio::strided_iterator< T >::strided_iterator ( vec,
const uint32  stride 
)
inline

constructor

Definition at line 78 of file strided_iterator.h.

Member Function Documentation

template<typename T>
NVBIO_FORCEINLINE NVBIO_HOST_DEVICE const_reference nvbio::strided_iterator< T >::operator* ( ) const
inline

const dereferencing operator

Definition at line 83 of file strided_iterator.h.

template<typename T>
NVBIO_FORCEINLINE NVBIO_HOST_DEVICE reference nvbio::strided_iterator< T >::operator* ( )
inline

dereferencing operator

Definition at line 88 of file strided_iterator.h.

template<typename T>
NVBIO_FORCEINLINE NVBIO_HOST_DEVICE strided_iterator<T> nvbio::strided_iterator< T >::operator+ ( const uint32  i) const
inline

addition

Definition at line 103 of file strided_iterator.h.

template<typename T>
NVBIO_FORCEINLINE NVBIO_HOST_DEVICE strided_iterator<T>& nvbio::strided_iterator< T >::operator++ ( )
inline

pre-increment

Definition at line 119 of file strided_iterator.h.

template<typename T>
NVBIO_FORCEINLINE NVBIO_HOST_DEVICE difference_type nvbio::strided_iterator< T >::operator- ( const strided_iterator< T >  it) const
inline

iterator subtraction

Definition at line 111 of file strided_iterator.h.

template<typename T>
NVBIO_FORCEINLINE NVBIO_HOST_DEVICE const_reference nvbio::strided_iterator< T >::operator[] ( const uint32  i) const
inline

const indexing operator

Definition at line 93 of file strided_iterator.h.

template<typename T>
NVBIO_FORCEINLINE NVBIO_HOST_DEVICE reference nvbio::strided_iterator< T >::operator[] ( const uint32  i)
inline

indexing operator

Definition at line 98 of file strided_iterator.h.

Member Data Documentation

template<typename T>
uint32 nvbio::strided_iterator< T >::m_stride

Definition at line 126 of file strided_iterator.h.

template<typename T>
T nvbio::strided_iterator< T >::m_vec

Definition at line 125 of file strided_iterator.h.


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