Alarm class handles all high level alarm tasks and management including adding, removing, providing interface for updating and defining crucial data for alarm functionality.
More...
#include <alarm.h>
Alarm class handles all high level alarm tasks and management including adding, removing, providing interface for updating and defining crucial data for alarm functionality.
◆ Alarm()
◆ getAlarm()
Helper methods.
Prompt the user for input selecting a valid existing alarm
- Returns
- See also
- AlarmData to the caller of this method
◆ handleAddAlarm()
void Alarm::handleAddAlarm |
( |
| ) |
|
|
private |
◆ handleOption()
void Alarm::handleOption |
( |
const int & | answer | ) |
|
|
private |
Run the input from user through switch statement to better handle many choices.
- Parameters
-
answer | Integer selection from options menu |
◆ handleQuit()
void Alarm::handleQuit |
( |
| ) |
|
|
private |
◆ handleRemoveAlarm()
void Alarm::handleRemoveAlarm |
( |
| ) |
|
|
private |
◆ handleRemoveAllAlarms()
void Alarm::handleRemoveAllAlarms |
( |
| ) |
|
|
private |
◆ handleToggleOnOffAlarm()
void Alarm::handleToggleOnOffAlarm |
( |
| ) |
|
|
private |
◆ handleUpdateAlarmDay()
void Alarm::handleUpdateAlarmDay |
( |
| ) |
|
|
private |
◆ handleUpdateAlarmTime()
void Alarm::handleUpdateAlarmTime |
( |
| ) |
|
|
private |
◆ includes()
bool Alarm::includes |
( |
const int & | dayCode, |
|
|
const std::vector< int > & | daysSelected ) |
|
private |
Checks if an integer exists within a vector.
- Parameters
-
dayCode | the integer in search for |
daysSelected | the vector you check in fir specified integer |
◆ loadAlarms()
void Alarm::loadAlarms |
( |
| ) |
|
|
private |
For easy interfacing between days of the week an alarm is triggered and the integer which represents them.
- See also
- daysOfTheWeek map
All user alarms to be stored in this vector from persistent memory and ram
◆ printOptions()
void Alarm::printOptions |
( |
| ) |
|
|
private |
Print and prompt user for input to be handled.
◆ setAlarmDays()
void Alarm::setAlarmDays |
( |
AlarmData & | alarmToUpdate | ) |
|
|
private |
◆ setAlarmMeridiem()
void Alarm::setAlarmMeridiem |
( |
AlarmData & | alarmToUpdate | ) |
|
|
private |
Alarm instance updating methods.
- Parameters
-
alarmToUpdate | the alarm instance needing to be updated |
- See also
- AlarmData
◆ setAlarmTime()
void Alarm::setAlarmTime |
( |
AlarmData & | alarmToUpdate | ) |
|
|
private |
The documentation for this class was generated from the following files: