IPPL API Reference
Independent Parallel Particle Layer C++ API
Loading...
Searching...
No Matches
ippl::Index Class Reference

Classes

class  iterator
 

Public Member Functions

KOKKOS_INLINE_FUNCTION Index ()
 
KOKKOS_INLINE_FUNCTION Index (size_t n)
 
KOKKOS_INLINE_FUNCTION Index (int f, int l)
 
KOKKOS_INLINE_FUNCTION Index (int f, int l, int s)
 
KOKKOS_INLINE_FUNCTION int min () const noexcept
 
KOKKOS_INLINE_FUNCTION int max () const noexcept
 
KOKKOS_INLINE_FUNCTION size_t length () const noexcept
 
KOKKOS_INLINE_FUNCTION int stride () const noexcept
 
KOKKOS_INLINE_FUNCTION int first () const noexcept
 
KOKKOS_INLINE_FUNCTION int last () const noexcept
 
KOKKOS_INLINE_FUNCTION bool empty () const noexcept
 
KOKKOS_INLINE_FUNCTION Indexoperator+= (int)
 
KOKKOS_INLINE_FUNCTION Indexoperator-= (int)
 
KOKKOS_INLINE_FUNCTION Index intersect (const Index &) const
 
KOKKOS_INLINE_FUNCTION Index grow (int ncells) const
 
KOKKOS_INLINE_FUNCTION bool touches (const Index &a) const
 
KOKKOS_INLINE_FUNCTION bool contains (const Index &a) const
 
KOKKOS_INLINE_FUNCTION bool split (Index &l, Index &r) const
 
KOKKOS_INLINE_FUNCTION bool split (Index &l, Index &r, int i) const
 
KOKKOS_INLINE_FUNCTION bool split (Index &l, Index &r, double a) const
 
iterator begin ()
 
iterator end ()
 
KOKKOS_INLINE_FUNCTION bool operator< (const Index &r) const
 
KOKKOS_INLINE_FUNCTION bool operator== (const Index &r) const noexcept
 

Friends

KOKKOS_INLINE_FUNCTION friend Index operator+ (const Index &, int)
 
KOKKOS_INLINE_FUNCTION friend Index operator+ (int, const Index &)
 
KOKKOS_INLINE_FUNCTION friend Index operator- (const Index &, int)
 
KOKKOS_INLINE_FUNCTION friend Index operator- (int, const Index &)
 
KOKKOS_INLINE_FUNCTION friend Index operator- (const Index &)
 
KOKKOS_INLINE_FUNCTION friend Index operator* (const Index &, int)
 
KOKKOS_INLINE_FUNCTION friend Index operator* (int, const Index &)
 
KOKKOS_INLINE_FUNCTION friend Index operator/ (const Index &, int)
 

Constructor & Destructor Documentation

◆ Index() [1/4]

KOKKOS_INLINE_FUNCTION ippl::Index::Index ( )

Instantiate Index without any range.

◆ Index() [2/4]

KOKKOS_INLINE_FUNCTION ippl::Index::Index ( size_t  n)

Instantiate Index with range [0, ..., n-1]

Parameters
nnumber of elements

◆ Index() [3/4]

KOKKOS_INLINE_FUNCTION ippl::Index::Index ( int  f,
int  l 
)

Instantiate Index with user-defined lower and upper bound [f, ..., l].

Parameters
ffirst element
llast element

◆ Index() [4/4]

KOKKOS_INLINE_FUNCTION ippl::Index::Index ( int  f,
int  l,
int  s 
)

First to Last using Step.

Parameters
ffirst element
llast element
sstep

Member Function Documentation

◆ empty()

KOKKOS_INLINE_FUNCTION bool ippl::Index::empty ( ) const
noexcept
Returns
true if empty, otherwise false

◆ first()

KOKKOS_INLINE_FUNCTION int ippl::Index::first ( ) const
noexcept
Returns
the first element

◆ last()

KOKKOS_INLINE_FUNCTION int ippl::Index::last ( ) const
noexcept
Returns
the last element

◆ length()

KOKKOS_INLINE_FUNCTION size_t ippl::Index::length ( ) const
noexcept
Returns
the number of elements

◆ max()

KOKKOS_INLINE_FUNCTION int ippl::Index::max ( ) const
noexcept
Returns
the largest element

◆ min()

KOKKOS_INLINE_FUNCTION int ippl::Index::min ( ) const
noexcept
Returns
the smallest element

◆ stride()

KOKKOS_INLINE_FUNCTION int ippl::Index::stride ( ) const
noexcept
Returns
the stride

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