Timetabler
|
Class for parser. More...
#include <parser.h>
Public Member Functions | |
Parser (Timetabler *) | |
Constructs the Parser object. More... | |
void | parseFields (std::string file) |
Parse the fields given in a file. More... | |
void | parseInput (std::string file) |
Parses the input given in a file. More... | |
void | addVars () |
Requests for variables to be added to the solver and stores the data. | |
bool | verify () |
Verifies if the input is valid. More... | |
Class for parser.
This class is responsible for parsing the field and inputs given by the user, and populating the corresponding data members.
Parser::Parser | ( | Timetabler * | timetabler | ) |
Constructs the Parser object.
timetabler | The time tabler |
Definition at line 12 of file parser.cpp.
References timetabler.
void Parser::parseFields | ( | std::string | file | ) |
Parse the fields given in a file.
[in] | file | The file containing the fields |
Definition at line 19 of file parser.cpp.
void Parser::parseInput | ( | std::string | file | ) |
Parses the input given in a file.
[in] | file | The file containig the input |
Definition at line 129 of file parser.cpp.
References Timetabler::data, Data::existingAssignmentVars, Global::FIELD_COUNT, and timetabler.
bool Parser::verify | ( | ) |
Verifies if the input is valid.
Definition at line 246 of file parser.cpp.
References Data::courses, Timetabler::data, isMinorCourse, Data::predefinedClausesWeights, Data::slots, and timetabler.