ECF 1.5
Prog2.h
1
7{
8public:
9 // 2 subtrees
10 Prog2()
11 {
12 nArguments_ = 2;
13 name_ = "p2";
14 }
15
16 void execute(void* evalOp, Tree::Tree& tree)
17 {
18 // execute all subtrees
19 getNextArgument(evalOp, tree);
20 getNextArgument(evalOp, tree);
21 }
22
23 ~Prog2()
24 { }
25};
GP function, executes 2 subtrees in sequence.
Definition: Prog2.h:7
void execute(void *evalOp, Tree::Tree &tree)
Execute the primitive.
Definition: Prog2.h:16
Base primitive class (Tree genotype).
Definition: Primitive.h:37
void getNextArgument(void *result, Tree &tree)
Execute next child node's primitive (execute next subtree).
Definition: Primitive.cpp:71
Tree class - implements genotype as a tree.
Definition: Tree_c.h:29