Package jmt.gui.jsim.panels

Examples of jmt.gui.jsim.panels.AllStationsParametersPanel


    setIconImage(JMTImageLoader.loadImageAwt("JSIMIcon"));
    this.centerWindow();
    classes = new ClassesPanel(model);
    stations = new StationsPanel(model, model);
    connections = new ConnectionsPanel(model);
    parameters = new AllStationsParametersPanel(model, model);
    measures = new MeasurePanel(model, model, model);
    rspl = new RSPLPanel(model, model, model);
    simulation = new SimulationPanel(model, model, model, this);
    parametricAnalysis = new ParametricAnalysisPanel(model, model, model, this);
    blocking = new AllBlockingRegionsPanel(model, model, model);
View Full Code Here


    else if ((problemType == ModelChecker.ERROR_PROBLEM) && (problemSubType == ModelChecker.ALL_FORWARD_STATION_ARE_SINK_ERROR)) {
      tabbedPane.setSelectedIndex(2);
    }
    // if it's a routing error show the link panel
    else if ((problemType == ModelChecker.ERROR_PROBLEM) && (problemSubType == ModelChecker.ROUTING_ERROR)) {
      AllStationsParametersPanel temp = (AllStationsParametersPanel) tabbedPane.getComponent(3);
      //set temp to show routing section panel
      temp.showStationParameterPanel(relatedStation, relatedClass, 2);
      tabbedPane.setSelectedIndex(3);
    }
    //if no measure have been defined show the measure panel
    else if ((problemType == ModelChecker.ERROR_PROBLEM) && (problemSubType == ModelChecker.SIMULATION_ERROR)) {
      tabbedPane.setSelectedIndex(4);
    }
    //if a measure is inconsistent (i.e have one or more 'null' field) show performance indices panel
    else if ((problemType == ModelChecker.ERROR_PROBLEM) && (problemSubType == ModelChecker.INCONSISTENT_MEASURE_ERROR)) {
      tabbedPane.setSelectedIndex(4);
    }
    //if a measure was defined more than once ask to delete the redundant measure
    else if ((problemSubType == ModelChecker.DUPLICATE_MEASURE_ERROR) && (problemType == ModelChecker.ERROR_PROBLEM)) {
      int k = JOptionPane.showConfirmDialog(null, "Delete all redundant performance indices?\n", "Redundant performance indices found",
          JOptionPane.ERROR_MESSAGE);
      if (k == 0) {
        mc.deleteRedundantMeasure();
      }
    }
    //if it is a reference station error show the reference station panel
    else if ((problemType == ModelChecker.ERROR_PROBLEM) && (problemSubType == ModelChecker.REFERENCE_STATION_ERROR)) {
      tabbedPane.setSelectedIndex(5);
    } else if ((problemType == ModelChecker.ERROR_PROBLEM) && (problemSubType == ModelChecker.JOIN_WITHOUT_FORK_ERROR)) {
      JOptionPane.showMessageDialog(this, "One or more join found but no fork. Please, remove al join or add a fork");
      tabbedPane.setSelectedIndex(1);
    }

    //used only in JMVA conversion
    else if ((problemSubType == ModelChecker.BCMP_DIFFERENT_QUEUEING_STRATEGIES_WARNING) && (problemType == ModelChecker.WARNING_PROBLEM)) {
      String name = getModel().getStationName(relatedStation);
      int k = JOptionPane
          .showConfirmDialog(
              null,
              "According to BCMP theorem hypothesis each station must have the same queue\nstrategy for each class, but different per class queue strategy were found at "
                  + name + ".\nDo you want to edit " + name + " queue strategy?\n\n", "Mixed queue strategy found",
              JOptionPane.WARNING_MESSAGE);
      if (k == 0) {
        AllStationsParametersPanel temp = (AllStationsParametersPanel) tabbedPane.getComponent(3);
        //set the station parameter panel to show the queue section
        temp.showStationParameterPanel(relatedStation, null, 0);
        tabbedPane.setSelectedIndex(3);
      }
    }
    //used only in JMVA conversion
    else if ((problemSubType == ModelChecker.BCMP_FCFS_DIFFERENT_SERVICE_TYPES_WARNING) && (problemType == ModelChecker.WARNING_PROBLEM)) {
      String name = getModel().getStationName(relatedStation);
      int k = JOptionPane.showConfirmDialog(null,
          "According to BCMP theorem hypothesis, a FCFS server must have the same service times for each class,\nbut at " + name
              + " the service strategy is mixed, i.e. both load dependent and independent were found.\nDo you want to edit " + name
              + " service parameters?\n\n", "Mixed service strategies found", JOptionPane.WARNING_MESSAGE);
      if (k == 0) {
        AllStationsParametersPanel temp = (AllStationsParametersPanel) tabbedPane.getComponent(3);
        //set the station parameter panel to show the service section
        temp.showStationParameterPanel(relatedStation, null, 1);
        tabbedPane.setSelectedIndex(3);
      }
    }
    //used only in JMVA conversion
    else if ((problemSubType == ModelChecker.BCMP_FCFS_EXPONENTIAL_WARNING) && (problemType == ModelChecker.WARNING_PROBLEM)) {
      String name = getModel().getStationName(relatedStation);
      int k = JOptionPane.showConfirmDialog(null,
          "According to BCMP theorem hypothesis, in a FCFS server all the service time distribution\nmust be exponential, but at " + name
              + " at least one non exponential distribution was found.\nDo you want to edit " + name + " service parameters?\n\n",
          "Non exponential distribution in FCFS server", JOptionPane.WARNING_MESSAGE);
      if (k == 0) {
        AllStationsParametersPanel temp = (AllStationsParametersPanel) tabbedPane.getComponent(3);
        //set the station parameter panel to show the service section
        temp.showStationParameterPanel(relatedStation, null, 1);
        tabbedPane.setSelectedIndex(3);
      }
    }
    //used only in JMVA conversion
    else if ((problemSubType == ModelChecker.BCMP_FCFS_DIFFERENT_SERVICE_TIMES_WARNING) && (problemType == ModelChecker.WARNING_PROBLEM)) {
      String name = getModel().getStationName(relatedStation);
      int k = JOptionPane
          .showConfirmDialog(
              null,
              "According to BCMP theorem hypothesis, in a FCFS server all the per class service time mean values\nmust be the same. If the service strategies are load dependent the mean value in each range\nhas to be the same for each class.\nDo you want to edit "
                  + name + " service parameters?\n\n", "Non exponential distribution in FCFS server", JOptionPane.WARNING_MESSAGE);
      if (k == 0) {
        AllStationsParametersPanel temp = (AllStationsParametersPanel) tabbedPane.getComponent(3);
        //set the station parameter panel to show the queue section
        temp.showStationParameterPanel(relatedStation, null, 1);
        tabbedPane.setSelectedIndex(3);
      }
    }
    //used only in JMVA conversion
    else if ((problemType == ModelChecker.WARNING_PROBLEM) && (problemSubType == ModelChecker.BCMP_NON_STATE_INDEPENDENT_ROUTING_WARNING)) {
View Full Code Here

TOP

Related Classes of jmt.gui.jsim.panels.AllStationsParametersPanel

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.