DaoManager.getElementDao().addRoom(room);
room = DaoManager.getElementDao().addRoom(room);
    public void actionPerformed(ActionEvent arg0) {        AddModifyElementWindow window = new AddModifyElementWindow(ElementDao.TYPE_ROOM);        window.show();                if (window.isOk()) {            Room room = new Room();            room.setName(window.getEquipmentName());            room.setDescription(window.getDescriptionEquipment());            room.setBuildingName(window.getBuildingName());                        try {                DaoManager.getElementDao().addRoom(room);                                mainFrame.getModel().fireRefreshRoom(room, BoTModel.TYPE_ADD);                                JOptionPane.showMessageDialog(null, "Ajout effectu avec succs", "Information", JOptionPane.INFORMATION_MESSAGE);            } catch (Exception e) {                JOptionPane.showMessageDialog(null, "Une erreur interne est survenue", "Erreur", JOptionPane.ERROR_MESSAGE);            }        }    }