Ignition Common

API Reference

4.1.0
MovingWindowFilter< T > Class Template Reference

Base class for MovingWindowFilter. More...

#include <MovingWindowFilter.hh>

Public Member Functions

 MovingWindowFilter ()
 Constructor. More...
 
virtual ~MovingWindowFilter ()
 Destructor. More...
 
void SetWindowSize (unsigned int _n)
 Set window size. More...
 
void Update (T _val)
 Update value of filter. More...
 
Value ()
 Get filtered result. More...
 
bool WindowFilled () const
 Get whether the window has been filled. More...
 
unsigned int WindowSize () const
 Get the window size. More...
 

Protected Member Functions

 MovingWindowFilter (MovingWindowFilterPrivate< T > &_d)
 Allow subclasses to initialize their own data pointer. More...
 

Protected Attributes

std::unique_ptr< MovingWindowFilterPrivate< T > > dataPtr
 Data pointer. More...
 

Detailed Description

template<typename T>
class ignition::common::MovingWindowFilter< T >

Base class for MovingWindowFilter.

Constructor & Destructor Documentation

◆ MovingWindowFilter() [1/2]

Constructor.

◆ ~MovingWindowFilter()

~MovingWindowFilter ( )
virtual

Destructor.

References MovingWindowFilter< T >::dataPtr.

◆ MovingWindowFilter() [2/2]

MovingWindowFilter ( MovingWindowFilterPrivate< T > &  _d)
explicitprotected

Allow subclasses to initialize their own data pointer.

Parameters
[in]_dReference to data pointer.

Member Function Documentation

◆ SetWindowSize()

void SetWindowSize ( unsigned int  _n)

Set window size.

Parameters
[in]_nnew desired window size

References MovingWindowFilter< T >::dataPtr.

◆ Update()

void Update ( _val)

Update value of filter.

Parameters
[in]_valnew raw value

References MovingWindowFilter< T >::dataPtr.

◆ Value()

T Value ( )

Get filtered result.

Returns
Latest filtered value

References MovingWindowFilter< T >::dataPtr.

◆ WindowFilled()

bool WindowFilled ( ) const

Get whether the window has been filled.

Returns
True if the window has been filled.

References MovingWindowFilter< T >::dataPtr.

◆ WindowSize()

unsigned int WindowSize ( ) const

Get the window size.

Returns
The size of the moving window.

References MovingWindowFilter< T >::dataPtr.

Member Data Documentation

◆ dataPtr


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