Public Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
Manager Class Reference

#include <manager.hpp>

Public Member Functions

bool addAndRunDevice (Sourcetype deviceType, std::string deviceName, UINT16 wantedId=0xFFFF)
 
bool addAndRunDevice (devices::BasicDevice *device, std::string deviceName, UINT16 wantedId=0xFFFF)
 
bool addApplication (Sourcetype appType, std::string appName, UINT16 wantedId=0xFFFF)
 
bool addApplication (application::BasicApplication *app, UINT16 wantedId=0xFFFF)
 
devices::BasicDevicegetDeviceById (UINT32 id)
 
devices::BasicDevicegetFirstDeviceByType (Sourcetype type)
 
bool importApplications ()
 
 Manager ()
 Default constructor. More...
 
bool runAllDevices ()
 
void setDeviceData (BasicData *data)
 
void stopAllDevices ()
 
 ~Manager ()
 Destructor. More...
 

Private Types

typedef std::vector< application::BasicApplication * > ApplicationList
 
typedef std::vector< devices::BasicDevice * > DeviceList
 

Private Member Functions

UINT16 getNextSourceId ()
 
void sourceThreadFunction (bool &endThread, UINT16 &waitTimeMs)
 

Private Attributes

ApplicationList m_appList
 
bool m_beVerbose
 
DeviceList m_deviceList
 
UINT16 m_nextSourceId
 
BasicDataBuffer m_sourceBuffer
 
Mutex m_sourceBufferMutex
 
SickThread< Manager,&Manager::sourceThreadFunctionm_sourceThread
 

Detailed Description

Definition at line 18 of file manager.hpp.

Member Typedef Documentation

Definition at line 48 of file manager.hpp.

typedef std::vector<devices::BasicDevice*> Manager::DeviceList
private

Definition at line 44 of file manager.hpp.

Constructor & Destructor Documentation

Manager::Manager ( )

Default constructor.

Definition at line 25 of file manager.cpp.

Manager::~Manager ( )

Destructor.

Definition at line 41 of file manager.cpp.

Member Function Documentation

bool Manager::addAndRunDevice ( Sourcetype  deviceType,
std::string  deviceName,
UINT16  wantedId = 0xFFFF 
)

Definition at line 91 of file manager.cpp.

bool Manager::addAndRunDevice ( devices::BasicDevice device,
std::string  deviceName,
UINT16  wantedId = 0xFFFF 
)

Definition at line 114 of file manager.cpp.

bool Manager::addApplication ( Sourcetype  appType,
std::string  appName,
UINT16  wantedId = 0xFFFF 
)

Definition at line 178 of file manager.cpp.

bool Manager::addApplication ( application::BasicApplication app,
UINT16  wantedId = 0xFFFF 
)

Definition at line 212 of file manager.cpp.

devices::BasicDevice * Manager::getDeviceById ( UINT32  id)

Definition at line 392 of file manager.cpp.

devices::BasicDevice * Manager::getFirstDeviceByType ( Sourcetype  type)

Definition at line 412 of file manager.cpp.

UINT16 Manager::getNextSourceId ( )
private

Definition at line 73 of file manager.cpp.

bool Manager::importApplications ( )
bool Manager::runAllDevices ( )

Kommando: Los...

Definition at line 240 of file manager.cpp.

void Manager::setDeviceData ( BasicData data)

Definition at line 291 of file manager.cpp.

void Manager::sourceThreadFunction ( bool &  endThread,
UINT16 waitTimeMs 
)
private

Thread-Funktion fuer das Verteilen der Daten.

Aus diesem Kontext heraus werden die Applikationen aufgerufen!

Pro Aufruf wird nur 1 Datum verteilt. Grund ist es, auch mit einem Prozessor den anderen Threads ggf. genug Rechenleistung zu ueberlassen. Hier koennten pro Aufruf aber auch mehr Daten verteilt werden, etwa wenn CAN-Nachrichten mit hoher Frequenz eintreffen.

Die Daten werden aktuell nicht an eine globale "Drain" weitergeleitet.

Definition at line 333 of file manager.cpp.

void Manager::stopAllDevices ( )

Definition at line 268 of file manager.cpp.

Member Data Documentation

ApplicationList Manager::m_appList
private

Definition at line 49 of file manager.hpp.

bool Manager::m_beVerbose
private

Definition at line 39 of file manager.hpp.

DeviceList Manager::m_deviceList
private

Definition at line 45 of file manager.hpp.

UINT16 Manager::m_nextSourceId
private

Definition at line 41 of file manager.hpp.

BasicDataBuffer Manager::m_sourceBuffer
private

Definition at line 52 of file manager.hpp.

Mutex Manager::m_sourceBufferMutex
private

Definition at line 55 of file manager.hpp.

SickThread<Manager, &Manager::sourceThreadFunction> Manager::m_sourceThread
private

Definition at line 54 of file manager.hpp.


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


libsick_ldmrs
Author(s): SICK AG , Martin Günther , Jochen Sprickerhof
autogenerated on Mon Oct 26 2020 03:27:30