SmartSoft Component-Developer API
Public Member Functions | List of all members
Smart::ISendServerHandler< DataType > Class Template Referenceabstract

Handler Class for SendServer for incoming commands. More...

#include <smartISendServerPattern_T.h>

Public Member Functions

virtual ~ISendServerHandler ()=default
 
virtual void handleSend (const DataType &data)=0
 Handler method for an incoming command. More...
 

Detailed Description

template<class DataType>
class Smart::ISendServerHandler< DataType >

Handler Class for SendServer for incoming commands.

Used by the SendServer to handle incoming commands. The user should provide the handleSend() method by subclassing and register an instance of this handler class with the SendServer.

Constructor & Destructor Documentation

◆ ~ISendServerHandler()

template<class DataType >
virtual Smart::ISendServerHandler< DataType >::~ISendServerHandler ( )
virtualdefault

Member Function Documentation

◆ handleSend()

template<class DataType >
virtual void Smart::ISendServerHandler< DataType >::handleSend ( const DataType &  data)
pure virtual

Handler method for an incoming command.

This method is called by the ISendServerPattern every time a new data is received. It must be provided by the component developer to handle incoming data. Since the method is executed by the communication thread, it must be very fast and non-blocking.

Usually the data will be inserted into a queue and another working thread processes the command. The IActiveQueueInputHandlerDecorator provides such a processing pattern.

Parameters
datacommunicated DataType object (Communication Object)

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