Symphony 1.0
Loading...
Searching...
No Matches
StudyState Class Reference

#include <study_path.h>

Inheritance diagram for StudyState:
Collaboration diagram for StudyState:

Public Member Functions

 StudyState (std::map< std::string, double > mastery_levels, double remaining_time)
 
void print () override
 Prints the state details.
 
- Public Member Functions inherited from State
 State ()
 Constructor for the State class.
 
virtual ~State ()
 Virtual destructor for the State class.
 

Public Attributes

std::map< std::string, double > mastery_levels
 
double remaining_time
 

Detailed Description

Definition at line 19 of file study_path.h.

Constructor & Destructor Documentation

◆ StudyState()

StudyState::StudyState ( std::map< std::string, double >  mastery_levels,
double  remaining_time 
)
inline

Definition at line 24 of file study_path.h.

std::map< std::string, double > mastery_levels
Definition study_path.h:21
double remaining_time
Definition study_path.h:22

Member Function Documentation

◆ print()

void StudyState::print ( )
inlineoverridevirtual

Prints the state details.

This method should be overridden by the user to display meaningful information about the state.

Reimplemented from State.

Definition at line 27 of file study_path.h.

27 {
28 for (const auto& [topic, mastery] : mastery_levels) {
29 std::cout << topic << ": " << mastery << "%\n";
30 }
31 std::cout << "Time left: " << remaining_time << " hours\n";
32 }

References mastery_levels, and remaining_time.

Member Data Documentation

◆ mastery_levels

std::map<std::string, double> StudyState::mastery_levels

Definition at line 21 of file study_path.h.

Referenced by print().

◆ remaining_time

double StudyState::remaining_time

Definition at line 22 of file study_path.h.

Referenced by StudyProblem::heuristic(), and print().


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