Package gov.nasa.arc.mct.fastplot.settings

Examples of gov.nasa.arc.mct.fastplot.settings.PlotConfiguration


      originalPlotMan.updateMonitoredGUI();
      originalPlotMan.updateMonitoredGUI(new AddChildEvent(nowPlus, feed1Component));
      originalPlotMan.updateMonitoredGUI(new RemoveChildEvent(nowPlus, feed1Component));
     
      PlotView thePlotView = originalPlotMan.getPlot();     
      PlotConfiguration settings = new PlotPersistenceHandler(originalPlotMan).loadPlotSettingsFromPersistance();
      PlotView secondPlotView =  PlotViewFactory.createPlotFromSettings(settings, 1, plotLabelingAlgorithm);
     
      // Should be different plots.
      Assert.assertNotSame(thePlotView, secondPlotView);
     
View Full Code Here


  public FeedProvider getFeedProvider(AbstractComponent component) {
 
    List<FeedProvider> feedProviders = component.getCapabilities(FeedProvider.class);
 
    String viewStateFilter = null;
    PlotConfiguration settings = plotPersistenceHandler.loadPlotSettingsFromPersistance();
    String persistedState = settings != null ? settings.getTimeSystemSetting() : null;
    String assignedComponentState = (plotDataAssigner != null) ? plotDataAssigner.getTimeSystemDefaultChoice() : null;
 
    if (persistedState != null && !persistedState.isEmpty()) {
      viewStateFilter = persistedState;
    } else {
View Full Code Here

    MockitoAnnotations.initMocks(this);
    labelingAlgorithm = new AbbreviatingPlotLabelingAlgorithm();
  }

  private PlotConfiguration initSettings(long minTime, long maxTime, boolean pinAxis, TimeAxisSubsequentBoundsSetting subsequentSetting) {
    PlotConfiguration settings = new PlotSettings();
    settings.setAxisOrientationSetting(AxisOrientationSetting.X_AXIS_AS_TIME);
    settings.setXAxisMaximumLocation(XAxisMaximumLocationSetting.MAXIMUM_AT_RIGHT);
    settings.setYAxisMaximumLocation(YAxisMaximumLocationSetting.MAXIMUM_AT_TOP);
    settings.setNonTimeAxisSubsequentMaxSetting(NonTimeAxisSubsequentBoundsSetting.SEMI_FIXED);
    settings.setNonTimeAxisSubsequentMinSetting(NonTimeAxisSubsequentBoundsSetting.SEMI_FIXED);

    settings.setTimeAxisSubsequentSetting(subsequentSetting);
    settings.setMinTime(minTime);
    settings.setMaxTime(maxTime);
    settings.setPinTimeAxis(pinAxis);
    return settings;
  }
View Full Code Here

    PlotSettings plotSettings = new PlotSettings();
    plotSettings.setTimeAxisSubsequentSetting(TimeAxisSubsequentBoundsSetting.SCRUNCH);

    h.persistPlotSettings(plotSettings);
    manifestation.getViewProperties().setProperty(PlotConstants.TIME_AXIS_SUBSEQUENT_SETTING, "FIXED");
    PlotConfiguration settings = h.loadPlotSettingsFromPersistance();

    Assert.assertEquals(settings.getTimeAxisSubsequentSetting(), TimeAxisSubsequentBoundsSetting.JUMP);
    Assert.assertTrue(settings.getPinTimeAxis());
  }
View Full Code Here

  }

  @Test
  public void testPlotMatchSettings(){   
   
    PlotConfiguration plotSettings = new PlotSettings();

    // Create a second set of settings with defaults...
    PlotConfiguration otherPlotSettings = new PlotSettings();
    // ...but explicitly make sure min/max times match
    // (these are defined relative to "now", resulting in intermittent test failures otherwise)
    otherPlotSettings.setMinTime(plotSettings.getMinTime());
    otherPlotSettings.setMaxTime(plotSettings.getMaxTime());
    PlotView basePlot = new PlotView.Builder(PlotterPlot.class).plotSettings(otherPlotSettings).build();

   
    Assert.assertTrue(basePlot.plotMatchesSetting(plotSettings));
   
View Full Code Here

TOP

Related Classes of gov.nasa.arc.mct.fastplot.settings.PlotConfiguration

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.