X-Git-Url: https://git.llucax.com/z.facultad/75.42/plaqui.git/blobdiff_plain/6f0378c3b23f392a1f342106932a90486bd05dbc..5e9414c4a70c6f2a33f399dd1f92a3adf3fe73ea:/Model/src/main.cpp diff --git a/Model/src/main.cpp b/Model/src/main.cpp index 3efdf8e..e6e52b5 100644 --- a/Model/src/main.cpp +++ b/Model/src/main.cpp @@ -8,25 +8,21 @@ #include "drainage.h" #include "exclusa.h" #include -#include "simulador.h" +#include +#include "simulator.h" using namespace std; using namespace PlaQui::Model; int main(int argc, char *argv[]) { - Simulador *sim = new Simulador(); - - sim->add_pump("bomba1"); - sim->add_conduct("c"); - sim->add_drainage("d"); - - sim->connect("bomba1", "c", IConector::OUT); - sim->connect("c", "d", IConector::OUT); + Simulator *sim = new Simulator(argv[1]); int i=0; - while (i<10) { + while (i<2) { sim->simulate(); + + std::cout << sim->get_state_as_xml() << std::endl << std::endl; i++; }