Beispiel #1
0
 /** Create a new station model */
 protected void doNew() {
   if (!okToChange()) {
     return;
   }
   String newName = smm.doNew(this, "New", "model", "Provide a name for the model");
   if (newName == null) {
     return;
   }
   setStationModel(new StationModel(newName, new ArrayList()), true);
   smm.addUsers(getStationModel());
 }
Beispiel #2
0
 /** Rename the current station model */
 protected void doRename() {
   if (!okToChange()) {
     return;
   }
   String newName = smm.doNew(this, "Rename", stationModel.getName(), "Use '>' to add categories");
   if (newName == null) {
     return;
   }
   doSave(false);
   StationModel sm = getStationModel();
   sm.setName(newName);
   setStationModel(sm, false);
   doSave(true);
 }