MADARA  3.4.1
madara::filters::DynamicPrefixPrint Class Reference

Filter for printing variables as they arrive and excluding prefixes that are unwanted via a user-specified MADARA StringVector container. More...

#include <DynamicPrefixPrint.h>

Inheritance diagram for madara::filters::DynamicPrefixPrint:
madara::filters::AggregateFilter

Public Member Functions

 DynamicPrefixPrint (const std::string &string_vector_name=".prefixes")
 Constructor. More...
 
virtual ~DynamicPrefixPrint ()=default
 Destructor. More...
 
virtual void filter (knowledge::KnowledgeMap &records, const transport::TransportContext &transport_context, knowledge::Variables &vars)
 Prints records and transport context information. More...
 

Public Attributes

std::string name
 The string vector name to bind to inside the knowledge base. More...
 

Protected Attributes

knowledge::containers::StringVector prefixes_
 A map of discovered peers. More...
 

Private Attributes

bool initialized_
 Tracks if the prefix vector has been initialized. More...
 

Detailed Description

Filter for printing variables as they arrive and excluding prefixes that are unwanted via a user-specified MADARA StringVector container.

Definition at line 28 of file DynamicPrefixPrint.h.

Constructor & Destructor Documentation

◆ DynamicPrefixPrint()

madara::filters::DynamicPrefixPrint::DynamicPrefixPrint ( const std::string &  string_vector_name = ".prefixes")
inline

Constructor.

Parameters
string_vector_namethe name of the string vector in the KB to use for prefix information

Definition at line 36 of file DynamicPrefixPrint.h.

◆ ~DynamicPrefixPrint()

virtual madara::filters::DynamicPrefixPrint::~DynamicPrefixPrint ( )
virtualdefault

Destructor.

Member Function Documentation

◆ filter()

virtual void madara::filters::DynamicPrefixPrint::filter ( knowledge::KnowledgeMap records,
const transport::TransportContext transport_context,
knowledge::Variables vars 
)
inlinevirtual

Prints records and transport context information.

Parameters
recordsthe aggregate records vector
transport_contextthe transport context where metadata is stored
varscontext for querying current program state

Implements madara::filters::AggregateFilter.

Definition at line 52 of file DynamicPrefixPrint.h.

Member Data Documentation

◆ initialized_

bool madara::filters::DynamicPrefixPrint::initialized_
private

Tracks if the prefix vector has been initialized.

Definition at line 158 of file DynamicPrefixPrint.h.

◆ name

std::string madara::filters::DynamicPrefixPrint::name

The string vector name to bind to inside the knowledge base.

Definition at line 164 of file DynamicPrefixPrint.h.

◆ prefixes_

knowledge::containers::StringVector madara::filters::DynamicPrefixPrint::prefixes_
protected

A map of discovered peers.

Definition at line 170 of file DynamicPrefixPrint.h.


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