43#include "data/constantHandler.h"
44#include "environment.h"
45#include "program/line.h"
69 std::vector<std::pair<Line*, bool>>
lines;
90 : environment{e}, constants{e.getNbConstant()}
104 : environment{other.environment}, lines{other.lines},
105 constants{other.constants}
110 lines.begin(), lines.end(), lines.begin(),
111 [](std::pair<Line*, bool>& otherLine)
112 -> std::pair<Line*, bool> {
113 return {new Line(*(otherLine.first)), otherLine.second};
152 Line& addNewLine(
const uint64_t idx);
175 void removeLine(
const uint64_t idx);
184 void swapLines(
const uint64_t idx0,
const uint64_t idx1);
200 size_t getNbLines()
const;
209 const Line& getLine(uint64_t index)
const;
218 Line& getLine(uint64_t index);
228 bool isIntron(uint64_t index)
const;
238 uint64_t identifyIntrons();
281 bool hasIdenticalBehavior(
const Program& other)
const;
Data::DataHandler used by Program::Program to handle their set of Constant values.
Definition: constantHandler.h:56
void resetData() override
Sets all elements of the Array to 0 (or its equivalent for the given template param....
Definition: primitiveTypeArray.h:169
The Environment class contains all information needed to execute a Program.
Definition: environment.h:84
const Environment & environment
Environment within which the Program will be executed.
Definition: program.h:56
Program(const Environment &e)
Main constructor of the Program.
Definition: program.h:89
Program()=delete
Delete the default constructor.
Program & operator=(const Program &other)=delete
Data::ConstantHandler constants
Constants of the Program.
Definition: program.h:77
Program(const Program &other)
Copy constructor of the Program.
Definition: program.h:103
std::vector< std::pair< Line *, bool > > lines
Lines of the program and intron property.
Definition: program.h:69
Data type used in Program::Program to define constant values, accessible to Instructions,...
Definition: constant.h:48