-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgenerator.hpp
31 lines (23 loc) · 852 Bytes
/
generator.hpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
// Copyright (c) 2010 Roy Sharon <[email protected]>
// See project repositry at <https://github.com/roysharon/Uniclasser>
// Using this file is subject to the MIT License <http://creativecommons.org/licenses/MIT/>
#ifndef GENERATOR_H
#define GENERATOR_H
#include <vector>
struct IGenerator;
struct IGeneratable
{
virtual void accept(IGenerator &generator) = 0;
};
#include "predicate.hpp"
struct IGenerator
{
virtual void visit(IPredicate &predicate) = 0;
virtual void visit(TerminalPredicate &predicate) = 0;
virtual void visit(AndPredicate &predicate) = 0;
virtual void visit(OrPredicate &predicate) = 0;
virtual void visit(TernaryPredicate &predicate) = 0;
virtual void generate(std::string classer_name, Predicate &p, codevalue_vector *test_codes, bool profiler) = 0;
virtual void finalize(bool test, bool profiler) = 0;
};
#endif