EX-Display
EX-Display
Loading...
Searching...
No Matches
Screen Class Reference

Class for each screen as received from the EXRAIL SCREEN() command Each Screen instance contains a linked list of ScreenRow instances Screen instances are contained in a linked list managed separately by the ScreenManager. More...

#include <Screen.h>

Collaboration diagram for Screen:
[legend]

Public Member Functions

 Screen (uint8_t screenId)
 Constructor for each Screen instance.
 
uint8_t getId ()
 Get the ID for this screen instance.
 
void setNext (Screen *screen)
 Set the next Screen instance in the list.
 
ScreengetNext ()
 Get the next Screen instance in the list.
 
void updateScreenRow (uint8_t screenRowId, const char *text)
 Update the specified ScreenRow, or create it if it doesn't exist This will automatically maintain the linked list of ScreenRow instances Setting text to an empty string "" will delete the associated row from the list.
 
ScreenRowgetFirstScreenRow ()
 Get the first ScreenRow instance in the list.
 
ScreenRowgetScreenRowById (uint8_t screenRowId)
 Get the ScreenRow instance at the specified ID.
 
void setLogger (Logger *logger)
 Set the Logger instance.
 
 ~Screen ()
 Destructor for the Screen instance Will automatically clean up the associated ScreenRow list.
 

Private Member Functions

void _addScreenRow (uint8_t screenRowId, const char *text)
 Add a new ScreenRow to the list.
 
void _deleteScreenRow (ScreenRow *screenRow)
 Delete the specified ScreenRow and update the list accordingly.
 

Private Attributes

uint8_t _screenId
 
Screen_next
 
ScreenRow_firstScreenRow
 
Logger_logger
 

Detailed Description

Class for each screen as received from the EXRAIL SCREEN() command Each Screen instance contains a linked list of ScreenRow instances Screen instances are contained in a linked list managed separately by the ScreenManager.

Constructor & Destructor Documentation

◆ Screen()

Screen::Screen ( uint8_t  screenId)

Constructor for each Screen instance.

Parameters
screenIdID of this screen as set in EXRAIL SCREEN()

◆ ~Screen()

Screen::~Screen ( )

Destructor for the Screen instance Will automatically clean up the associated ScreenRow list.

Here is the call graph for this function:

Member Function Documentation

◆ _addScreenRow()

void Screen::_addScreenRow ( uint8_t  screenRowId,
const char *  text 
)
private

Add a new ScreenRow to the list.

Parameters
screenRowIdID of the ScreenRow to add
textText for this ScreenRow
Here is the call graph for this function:
Here is the caller graph for this function:

◆ _deleteScreenRow()

void Screen::_deleteScreenRow ( ScreenRow screenRow)
private

Delete the specified ScreenRow and update the list accordingly.

Parameters
screenRowPointer to the ScreenRow instance to delete
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getFirstScreenRow()

ScreenRow * Screen::getFirstScreenRow ( )

Get the first ScreenRow instance in the list.

Returns
Pointer to the first ScreenRow instance
Here is the caller graph for this function:

◆ getId()

uint8_t Screen::getId ( )

Get the ID for this screen instance.

Returns
Screen ID
Here is the caller graph for this function:

◆ getNext()

Screen * Screen::getNext ( )

Get the next Screen instance in the list.

Returns
Pointer to the next Screen instance
Here is the caller graph for this function:

◆ getScreenRowById()

ScreenRow * Screen::getScreenRowById ( uint8_t  screenRowId)

Get the ScreenRow instance at the specified ID.

Parameters
screenRowIdScreenRow ID to retrieve
Returns
Pointer to the ScreenRow instance at the ID
Here is the call graph for this function:
Here is the caller graph for this function:

◆ setLogger()

void Screen::setLogger ( Logger logger)

Set the Logger instance.

Parameters
loggerPointer to the Logger
Here is the caller graph for this function:

◆ setNext()

void Screen::setNext ( Screen screen)

Set the next Screen instance in the list.

Parameters
screenPointer to the next Screen instance
Here is the caller graph for this function:

◆ updateScreenRow()

void Screen::updateScreenRow ( uint8_t  screenRowId,
const char *  text 
)

Update the specified ScreenRow, or create it if it doesn't exist This will automatically maintain the linked list of ScreenRow instances Setting text to an empty string "" will delete the associated row from the list.

Parameters
screenRowIdScreenRow ID
textText to associated with this ScreenRow
Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ _firstScreenRow

ScreenRow* Screen::_firstScreenRow
private

◆ _logger

Logger* Screen::_logger
private

◆ _next

Screen* Screen::_next
private

◆ _screenId

uint8_t Screen::_screenId
private

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