dignea  1.0.0
Diverse Instance Generator with Novelty Search and Evolutionary Algorithms
Crossover.h
1 //
2 // Created by amarrero on 17/10/19.
3 //
4 
5 #ifndef DIGNEA_CROSSOVER_H
6 #define DIGNEA_CROSSOVER_H
7 
8 #include <dignea/core/Solution.h>
9 
10 #include <memory>
11 
12 using namespace std;
13 
18 template <class S>
19 class Crossover {
20  public:
21  Crossover() = default;
22 
23  virtual ~Crossover() = default;
24 
25  public:
34  virtual void run(S &firstInd, S &secondInd) = 0;
35 
36  virtual std::string getName() const = 0;
37 };
38 
39 #endif // DIGNEA_CROSSOVER_H
Abstract Crossover interface.
Definition: Crossover.h:19
virtual void run(S &firstInd, S &secondInd)=0
Method to perform the crossover operation. This is a virtual method that must be implemented in the s...