HomeWaterLeaksDetection
HTMLDataSource Class Referenceabstract

#include <HTMLDataSource.h>

Public Member Functions

virtual const String getHTMLData (const int id) const =0
 If a class is registered as a source of data for the HTML content, it needs return the appropriate value according to the id given as a parameter. More...
 

Static Public Attributes

static const String UNDEFINED_DATA = String("UNDEFINED")
 string "UNDEFINED" More...
 

Detailed Description

Author
silhavyj A17B0362P

This class works as an abstract class/interface for all classes that are registered as a source of data for the HTML content. All these classes must implement the method(s) defined within this interface.

Definition at line 15 of file HTMLDataSource.h.

Member Function Documentation

◆ getHTMLData()

virtual const String HTMLDataSource::getHTMLData ( const int  id) const
pure virtual

If a class is registered as a source of data for the HTML content, it needs return the appropriate value according to the id given as a parameter.

Parameters
id- the id of the piece of data
Returns
If the class holds this piece of information, it will return it. Otherwise, "UNDEFINED" will be returned.

Implemented in LeaksController, FreeMemoryMeasurement, HighLeakDetection, LowLeakDetection, TotalLeakDetection, DateTime, EmailSender, and PulseCounter.

Member Data Documentation

◆ UNDEFINED_DATA

const String HTMLDataSource::UNDEFINED_DATA = String("UNDEFINED")
static

string "UNDEFINED"

Definition at line 17 of file HTMLDataSource.h.

Referenced by WebServer::replaceHTMLWithData().


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