Grader
Grader Class Reference

#include <Grader.h>

Public Member Functions

std::shared_ptr< RubricItemcreateRubricItem ()
 
std::shared_ptr< RubricItemcreateRubricItem (const std::string &)
 
std::shared_ptr< RubricItemcreateRubricItem (const std::function< bool()> &)
 
void run ()
 
void run_debug ()
 
bool failed ()
 
bool passed ()
 
nlohmann::json resultsJson ()
 
std::string results ()
 

Public Attributes

bool has_evaluated = false
 
Stats stats
 

Detailed Description

The main Grader tool. Responsible for creating RubricItems, running them and then outputting results.

Member Function Documentation

§ createRubricItem() [1/3]

shared_ptr< RubricItem > Grader::createRubricItem ( )

Generates a RubricItem.

§ createRubricItem() [2/3]

std::shared_ptr<RubricItem> Grader::createRubricItem ( const std::string &  )

Generates a RubricItem.

§ createRubricItem() [3/3]

std::shared_ptr<RubricItem> Grader::createRubricItem ( const std::function< bool()> &  )

Generates a RubricItem.

§ failed()

bool Grader::failed ( )

Whether or not the Grader as a whole has failed.

§ passed()

bool Grader::passed ( )

Whether or not the Grader as a whole has passed. Every RubricItem must pass or be optional for this to be true.

§ results()

string Grader::results ( )

Get a stringified JSON representation of the evaluation results. Good for outputting to another environment.

§ resultsJson()

json Grader::resultsJson ( )

Get a JSON representation of the evaluation results.

§ run()

void Grader::run ( )

Evaluates all RubricItems and respects checkpoint and optional flags.

§ run_debug()

void Grader::run_debug ( )

Evaluates all RubricItems regardless of flags.

Member Data Documentation

§ has_evaluated

bool Grader::has_evaluated = false

True after it completes evaluating RubricItems

§ stats

Stats Grader::stats

Stores and generates info on evaluated RubricItems. public for testing purposes


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