fpmas 1.6
Public Member Functions | List of all members
fpmas::synchro::hard::api::Server Class Referenceabstract

#include <client_server.h>

Inheritance diagram for fpmas::synchro::hard::api::Server:
Inheritance graph
[legend]

Public Member Functions

virtual void setEpoch (Epoch epoch)=0
 
virtual Epoch getEpoch () const =0
 
virtual void handleIncomingRequests ()=0
 

Detailed Description

Generic server API.

This interface is notably used by the generic TerminationAlgorithm to keep handling requests of any server until termination is detected.

Since termination is determined by "step", an odd or even Epoch is used to describe the current state of the server, so that messages sent in an odd period can't be received in an even period and vice versa.

the handleIncomingRequests() method is also extensively used to prevent deadlock situations.

Member Function Documentation

◆ setEpoch()

virtual void fpmas::synchro::hard::api::Server::setEpoch ( Epoch  epoch)
pure virtual

◆ getEpoch()

virtual Epoch fpmas::synchro::hard::api::Server::getEpoch ( ) const
pure virtual

◆ handleIncomingRequests()

virtual void fpmas::synchro::hard::api::Server::handleIncomingRequests ( )
pure virtual

Performs the full reception cycle associated to this server.

If at least one request supposed to be handled by this server is pending, the server must handle at least one of those request to ensure progress and avoid deadlock situations.

Implemented in fpmas::synchro::hard::hard_link::LinkServer< T >, fpmas::synchro::hard::MutexServer< T >, fpmas::synchro::hard::VoidServer, and fpmas::synchro::hard::ServerPackBase.


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