helib::PtrVector_slice< T > Struct Template Reference

An implementation of PtrVector as a slice of another PtrVector. More...

#include <PtrVector.h>

Inheritance diagram for helib::PtrVector_slice< T >:
helib::PtrVector< T >

Public Member Functions

 PtrVector_slice (const PtrVector_slice< T > &slice, long from, long _sz=-1)
 
 PtrVector_slice (const PtrVector< T > &_orig, long from, long _sz=-1)
 
T * operator[] (long i) const override
 
long size () const override
 
long numNonNull (long first=0, long last=LONG_MAX) const override
 
const T * ptr2nonNull () const override
 
- Public Member Functions inherited from helib::PtrVector< T >
virtual void resize (long newSize, UNUSED const PtrVector *another=nullptr)
 
virtual ~PtrVector ()
 
bool isSet (long i) const
 

Public Attributes

const PtrVector< T > & orig
 
long start
 
long sz
 

Detailed Description

template<typename T>
struct helib::PtrVector_slice< T >

An implementation of PtrVector as a slice of another PtrVector.

Constructor & Destructor Documentation

◆ PtrVector_slice() [1/2]

template<typename T >
helib::PtrVector_slice< T >::PtrVector_slice ( const PtrVector_slice< T > &  slice,
long  from,
long  _sz = -1 
)
inline

◆ PtrVector_slice() [2/2]

template<typename T >
helib::PtrVector_slice< T >::PtrVector_slice ( const PtrVector< T > &  _orig,
long  from,
long  _sz = -1 
)
inline

Member Function Documentation

◆ numNonNull()

template<typename T >
long helib::PtrVector_slice< T >::numNonNull ( long  first = 0,
long  last = LONG_MAX 
) const
inlineoverridevirtual

Reimplemented from helib::PtrVector< T >.

◆ operator[]()

template<typename T >
T* helib::PtrVector_slice< T >::operator[] ( long  i) const
inlineoverridevirtual

Implements helib::PtrVector< T >.

◆ ptr2nonNull()

template<typename T >
const T* helib::PtrVector_slice< T >::ptr2nonNull ( ) const
inlineoverridevirtual

Reimplemented from helib::PtrVector< T >.

◆ size()

template<typename T >
long helib::PtrVector_slice< T >::size ( ) const
inlineoverridevirtual

Implements helib::PtrVector< T >.

Member Data Documentation

◆ orig

template<typename T >
const PtrVector<T>& helib::PtrVector_slice< T >::orig

◆ start

template<typename T >
long helib::PtrVector_slice< T >::start

◆ sz

template<typename T >
long helib::PtrVector_slice< T >::sz