- Bomb *bomba;
- Conduct *canio1;
- Conduct *canio2;
-
- bomba = new Bomb("bomba");
- bomba->set_max_flow(3);
- canio1 = new Conduct("cond_1");
- canio1->set_max_flow(10);
- canio2 = new Conduct("cond_2");
- canio2->set_max_flow(5);
-
- bomba->connect(canio1, IConector::OUT);
- canio1->connect(bomba, IConector::IN);
- canio1->connect(canio2, IConector::OUT);
- canio2->connect(canio1, IConector::IN);
+/*
+ Pump *bomba1;
+ Exclusa *exclusa1;
+ Conduct *salida1;
+ Conduct *salida2;
+ Conduct *entrada;
+ Splitter *split;
+ Drainage *dren1, *dren2;
+
+
+ bomba1 = new Pump("bomba");
+ bomba1->set_max_flow(30);
+ salida1 = new Conduct("salida_1");
+ salida1->set_max_flow(2);
+ salida2 = new Conduct("salida_2");
+ salida2->set_max_flow(5);
+ exclusa1 = new Exclusa("exclusa1");
+
+ split = new Splitter("splitter");
+ split->set_max_flow(8);
+ entrada = new Conduct("entrada");
+ entrada->set_max_flow(10);
+
+ dren1 = new Drainage("drenaje1");
+ dren2 = new Drainage("drenaje2");
+
+ bomba1->connect(exclusa1, IConector::OUT);
+ exclusa1->connect(bomba1, IConector::IN);
+ exclusa1->connect(entrada, IConector::OUT);
+ entrada->connect(exclusa1, IConector::IN);
+ entrada->connect(split, IConector::OUT);
+ split->connect(entrada, IConector::IN);
+ split->connect(salida1, IConector::OUT);
+ split->connect(salida2, IConector::OUT);
+ salida1->connect(split, IConector::IN);
+ salida2->connect(split, IConector::IN);
+ salida1->connect(dren1, IConector::OUT);
+ salida2->connect(dren2, IConector::OUT);
+
+ //// LOGICA DE CONTROL!!
+ // CONECTO LA SALIDA DE LA EXCLUSA A LA ENTRADA DE LA BOMBA
+ bomba1->connect_input_logic( exclusa1->get_logic_output() );