ifw-fcf  2.0.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | List of all members
fcf::devmgr::common::TaskSetup Class Reference

#include <taskSetup.hpp>

Inheritance diagram for fcf::devmgr::common::TaskSetup:
testDeviceFacade::MyTaskSetup

Public Member Functions

 TaskSetup (const std::string &id, DataContext &data_ctx, DeviceFacade &device_facade, const std::any &payload)
 Class constructor. More...
 
virtual ~TaskSetup ()
 Default destructor. More...
 
void Run () override
 Thread run method. More...
 
 TaskSetup (const TaskSetup &)=delete
 Disable copy constructor. More...
 
TaskSetupoperator= (const TaskSetup &)=delete
 Disable assignment operator. More...
 

Detailed Description

This class implements a worker thread to manage a setup command. The thread will be active until the setup finishes successfully or when an error or timeout occurs. When the server receives a STOP command, the thread shall be stopped.

The TaskSetup reports the outcome of the setup action through events. The three events used are: SetupDone, SetupTimeout and SetupError.

This worker class prevent the Device Manager to block when managing parallel setup events.

Several worker threads can be running concurrently. Handling of conflicts between devices addressed in several setups shall be handled at the controller side.

See Also
rad::Activity

Constructor & Destructor Documentation

fcf::devmgr::common::TaskSetup::TaskSetup ( const std::string &  id,
DataContext data_ctx,
DeviceFacade device_facade,
const std::any &  payload 
)

Class constructor.

Parameters
[in]idThread ID
[in,out]data_ctxReference to data context object
[in,out]device_facadeReference to device facade object
[in]payloadsetup request object
fcf::devmgr::common::TaskSetup::~TaskSetup ( )
virtual

Default destructor.

fcf::devmgr::common::TaskSetup::TaskSetup ( const TaskSetup )
delete

Disable copy constructor.

Member Function Documentation

TaskSetup& fcf::devmgr::common::TaskSetup::operator= ( const TaskSetup )
delete

Disable assignment operator.

void fcf::devmgr::common::TaskSetup::Run ( )
override

Thread run method.

Do-activity to perform the actions of a setup command. The specific actions are defined by the payload of the setup message.


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