Bayes Filters Library
Public Member Functions | Private Attributes | List of all members
bfl::HistoryBuffer Class Reference

#include <HistoryBuffer.h>

Public Member Functions

 HistoryBuffer (const std::size_t state_size) noexcept
 
 HistoryBuffer (HistoryBuffer &&history_buffer) noexcept
 
HistoryBufferoperator= (HistoryBuffer &&history_buffer) noexcept
 
 ~HistoryBuffer () noexcept=default
 
void addElement (const Eigen::Ref< const Eigen::VectorXd > &element)
 
Eigen::MatrixXd getHistoryBuffer () const
 
bool setHistorySize (const unsigned int window)
 
unsigned int getHistorySize () const
 
bool decreaseHistorySize ()
 
bool increaseHistorySize ()
 
bool clear ()
 

Private Attributes

unsigned int window_ = 5
 
const unsigned int max_window_ = 30
 
std::deque< Eigen::VectorXd > history_buffer_
 
std::size_t state_size_
 

Detailed Description

Definition at line 20 of file HistoryBuffer.h.

Constructor & Destructor Documentation

◆ HistoryBuffer() [1/2]

HistoryBuffer::HistoryBuffer ( const std::size_t  state_size)
noexcept

Definition at line 14 of file HistoryBuffer.cpp.

◆ HistoryBuffer() [2/2]

HistoryBuffer::HistoryBuffer ( HistoryBuffer &&  history_buffer)
noexcept

Definition at line 19 of file HistoryBuffer.cpp.

◆ ~HistoryBuffer()

bfl::HistoryBuffer::~HistoryBuffer ( )
defaultnoexcept

Member Function Documentation

◆ addElement()

void HistoryBuffer::addElement ( const Eigen::Ref< const Eigen::VectorXd > &  element)

Definition at line 46 of file HistoryBuffer.cpp.

◆ clear()

bool HistoryBuffer::clear ( )

Definition at line 99 of file HistoryBuffer.cpp.

◆ decreaseHistorySize()

bool HistoryBuffer::decreaseHistorySize ( )

Definition at line 87 of file HistoryBuffer.cpp.

◆ getHistoryBuffer()

MatrixXd HistoryBuffer::getHistoryBuffer ( ) const

Definition at line 55 of file HistoryBuffer.cpp.

◆ getHistorySize()

unsigned int bfl::HistoryBuffer::getHistorySize ( ) const
inline

Definition at line 37 of file HistoryBuffer.h.

References window_.

◆ increaseHistorySize()

bool HistoryBuffer::increaseHistorySize ( )

Definition at line 93 of file HistoryBuffer.cpp.

◆ operator=()

HistoryBuffer & HistoryBuffer::operator= ( HistoryBuffer &&  history_buffer)
noexcept

Definition at line 29 of file HistoryBuffer.cpp.

References window_.

◆ setHistorySize()

bool HistoryBuffer::setHistorySize ( const unsigned int  window)

Definition at line 67 of file HistoryBuffer.cpp.

Member Data Documentation

◆ history_buffer_

std::deque<Eigen::VectorXd> bfl::HistoryBuffer::history_buffer_
private

Definition at line 51 of file HistoryBuffer.h.

◆ max_window_

const unsigned int bfl::HistoryBuffer::max_window_ = 30
private

Definition at line 49 of file HistoryBuffer.h.

◆ state_size_

std::size_t bfl::HistoryBuffer::state_size_
private

Definition at line 53 of file HistoryBuffer.h.

◆ window_

unsigned int bfl::HistoryBuffer::window_ = 5
private

Definition at line 47 of file HistoryBuffer.h.

Referenced by getHistorySize(), and operator=().


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