irioCoreCpp Library Module  2.1.0
irio::ProfileBase Class Reference

Base profile class. More...

#include <profileBase.h>

Inheritance diagram for irio::ProfileBase:

Public Member Functions

 ProfileBase (ParserManager *parserManager, const NiFpga_Session &session, const PROFILE_ID &id)
 Allows the user to access terminals for read/write operations. More...
 
template<typename T >
getTerminal () const
 Returns the specified terminal if it is present in the current profile. More...
 

Public Attributes

const PROFILE_ID profileID
 Profile type.
 

Protected Member Functions

template<typename T >
void addTerminal (T terminal)
 Adds a terminal to the profile. More...
 

Private Attributes

std::unordered_map< std::type_index, std::unique_ptr< TerminalsBase > > m_mapTerminals
 Associates a Terminal type to the actual instance of the terminal.
 

Detailed Description

Base profile class.

Allows the user to access terminals for read/write operations. If a terminal group is not in the profile, an irio::errors::TerminalNotImplementedError exception will be thrown.

Definition at line 22 of file profileBase.h.

Constructor & Destructor Documentation

◆ ProfileBase()

irio::ProfileBase::ProfileBase ( ParserManager parserManager,
const NiFpga_Session &  session,
const PROFILE_ID &  id 
)
explicit

Allows the user to access terminals for read/write operations.

Parameters
parserManagerPointer to class managing parsing the bitfile and finding its resources
sessionNiFpga_Session to be used in NiFpga related functions
idIdentification of the profile type

Member Function Documentation

◆ addTerminal()

template<typename T >
void irio::ProfileBase::addTerminal ( terminal)
protected

Adds a terminal to the profile.

Parameters
terminalThe terminal to be added.
Template Parameters
TThe type of the terminal.

◆ getTerminal()

template<typename T >
T irio::ProfileBase::getTerminal ( ) const

Returns the specified terminal if it is present in the current profile.

Exceptions
irio::errors::TerminalNotImplementedErrorTerminals group not present for the current profile
Template Parameters
TTerminals to get
Returns
Requested terminals

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