18 std::string generator_name,
22 auto res =
generators.insert({generator_name, build_generator});
26 std::unique_ptr<goto_harness_generatort>
28 const std::string &generator_name,
36 auto generator = it->second();
37 for(
const auto &option : generator_options)
39 generator->handle_option(option.first, option.second);
41 generator->validate_options(goto_model);
48 "unknown generator type",
55 [](
const std::pair<std::string, build_generatort> &value) {
std::map< std::string, build_generatort > generators
std::map< std::string, std::list< std::string > > generator_optionst
std::function< std::unique_ptr< goto_harness_generatort >()> build_generatort
the type of a function that produces a goto-harness generator.
std::unique_ptr< goto_harness_generatort > factory(const std::string &generator_name, const generator_optionst &generator_options, const goto_modelt &goto_model)
return a generator matching the generator name.
void register_generator(std::string generator_name, build_generatort build_generator)
register a new goto-harness generator with the given name.
Thrown when users pass incorrect command line arguments, for example passing no files to analysis or ...
#define GOTO_HARNESS_GENERATOR_TYPE_OPT
#define CHECK_RETURN(CONDITION)
#define PRECONDITION(CONDITION)
Stream & join_strings(Stream &&os, const It b, const It e, const Delimiter &delimiter, TransformFunc &&transform_func)
Prints items to an stream, separated by a constant delimiter.