- container_t vm_container = PJ_container_get(vm->getCname());
- simgrid::instr::Type* type = vm_container->type_->getChild("MSG_VM_STATE");
- simgrid::instr::Value* val = simgrid::instr::Value::byNameOrCreate("suspend", "1 0 0", type); // suspend is red
- new simgrid::instr::PushStateEvent(MSG_get_clock(), vm_container, type, val);
+ container_t vm_container = simgrid::instr::Container::byName(vm->getName());
+ simgrid::instr::Type* state = vm_container->type_->byName("MSG_VM_STATE");
+ state->addEntityValue("suspend", "1 0 0"); // suspend is red
+ new simgrid::instr::PushStateEvent(MSG_get_clock(), vm_container, state, state->getEntityValue("suspend"));