Examples of StarSelectorDialog


Examples of org.aavso.tools.vstar.ui.dialog.StarSelectorDialog

      public void actionPerformed(ActionEvent e) {
        try {
          // Prompt user for star and JD range selection.
          Mediator.getUI().getStatusPane().setMessage(
              LocaleProps.get("STATUS_PANE_SELECT_STAR"));
          StarSelectorDialog starSelectorDialog = StarSelectorDialog
              .getInstance();
          starSelectorDialog.showDialog();

          if (!starSelectorDialog.isCancelled()) {
            String starName = starSelectorDialog.getStarName();
            String auid = starSelectorDialog.getAuid();
            double minJD, maxJD;
            // TODO: consider doing these value mods in the dialog
            // getters to make this code more declarative.
            if (!starSelectorDialog.wantAllData()) {
              minJD = starSelectorDialog.getMinDate()
                  .getJulianDay();
              maxJD = starSelectorDialog.getMaxDate()
                  .getJulianDay();
            } else {
              minJD = 0;
              maxJD = Double.MAX_VALUE;
            }

            mediator.createObservationArtefactsFromDatabase(
                starName, auid, minJD, maxJD,
                starSelectorDialog.isLoadAdditive());
          } else {
            Mediator.getUI().getStatusPane().setMessage("");
          }
        } catch (Exception ex) {
          completeProgress();
View Full Code Here

Examples of org.aavso.tools.vstar.ui.dialog.StarSelectorDialog

  @Override
  public List<URL> getURLs() throws Exception {
    List<URL> urls = null;

    StarSelectorDialog dialog = StarSelectorDialog.getInstance();
    dialog.showDialog();

    if (!dialog.isCancelled()) {
      String urlStr = "http://test.aavso.org/apps/api/aid/observation";

      if (!dialog.wantAllData()) {
        urlStr += "?start=" + dialog.getMinDate().getJulianDay();
        urlStr += "&end=" + dialog.getMaxDate().getJulianDay();
      }

      if (urlStr.endsWith("observation")) {
        urlStr += "?";
      } else {
        urlStr += "&";
      }

      String auid = dialog.getAuid();
      String starName = dialog.getStarName();

      VSXWebServiceVOTableStarNameAndAUIDSource vsx = new VSXWebServiceVOTableStarNameAndAUIDSource();

      // TODO: just use auid or star name and tell Will to fix doc (not
      // just auid)
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.