Public Member Functions | Public Attributes | Private Member Functions
hayai::MainRunner Class Reference

Default main executable runner for Hayai. More...

#include <hayai_main.hpp>

List of all members.

Public Member Functions

 MainRunner ()
int ParseArgs (int argc, char **argv, std::vector< char * > *residualArgs=NULL)
 Parse arguments.
int Run ()
 Run the selected execution mode.
 ~MainRunner ()

Public Attributes

MainExecutionMode ExecutionMode
 Execution mode.
std::vector< FileOutputter * > FileOutputters
bool ShuffleBenchmarks
 Shuffle benchmarks.
OutputterStdoutOutputter

Private Member Functions

int ListBenchmarks ()
 List benchmarks.
int RunBenchmarks ()
 Run benchmarks.
void ShowUsage (const char *execName)
 Show usage.

Detailed Description

Default main executable runner for Hayai.

Definition at line 148 of file hayai_main.hpp.


Constructor & Destructor Documentation

Definition at line 151 of file hayai_main.hpp.

Definition at line 160 of file hayai_main.hpp.


Member Function Documentation

int hayai::MainRunner::ListBenchmarks ( ) [inline, private]

List benchmarks.

Returns:
the exit status code to be returned from the executable.

Definition at line 401 of file hayai_main.hpp.

int hayai::MainRunner::ParseArgs ( int  argc,
char **  argv,
std::vector< char * > *  residualArgs = NULL 
) [inline]

Parse arguments.

Parameters:
argcArgument count including the executable name.
argvArguments.
residualArgsPointer to vector to hold residual arguments after parsing. If not NULL, the parser will not fail upon encounting an unknown argument but will instead add it to the list of residual arguments and return a success code. Note: the parser will still fail if an invalid value is provided to a known argument.
Returns:
0 on success, otherwise the exit status code to be returned from the executable.

Definition at line 206 of file hayai_main.hpp.

int hayai::MainRunner::Run ( ) [inline]

Run the selected execution mode.

Returns:
the exit status code to be returned from the executable.

Definition at line 337 of file hayai_main.hpp.

int hayai::MainRunner::RunBenchmarks ( ) [inline, private]

Run benchmarks.

Returns:
the exit status code to be returned from the executable.

Definition at line 359 of file hayai_main.hpp.

void hayai::MainRunner::ShowUsage ( const char *  execName) [inline, private]

Show usage.

Parameters:
execNameExecutable name.

Definition at line 438 of file hayai_main.hpp.


Member Data Documentation

Execution mode.

Definition at line 175 of file hayai_main.hpp.

File outputters.

Outputter will be freed by the class on destruction.

Definition at line 185 of file hayai_main.hpp.

Shuffle benchmarks.

Definition at line 179 of file hayai_main.hpp.

Standard output outputter.

Will be freed by the class on destruction.

Definition at line 191 of file hayai_main.hpp.


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


hayai
Author(s): Nick Bruun
autogenerated on Thu Jun 6 2019 18:13:44