use of org.baderlab.csplugins.enrichmentmap.view.control.io.ViewParams.CutoffParam in project EnrichmentMapApp by BaderLab.
the class ControlPanelMediator method getAllViewParams.
public Map<Long, ViewParams> getAllViewParams() {
Map<Long, ViewParams> map = new HashMap<>();
getControlPanel().getAllControlPanels().forEach((suid, panel) -> {
CutoffParam cuttofParam = panel.getPValueRadio().isSelected() ? CutoffParam.P_VALUE : CutoffParam.Q_VALUE;
Double pVal = panel.getPValueSliderPanel() != null ? panel.getPValueSliderPanel().getValue() : null;
Double qVal = panel.getQValueSliderPanel() != null ? panel.getQValueSliderPanel().getValue() : null;
Double sCoeff = panel.getSimilaritySliderPanel() != null ? panel.getSimilaritySliderPanel().getValue() : null;
Set<AbstractDataSet> uncheckedDataSets = panel.getUncheckedDataSets();
Set<String> filteredDataSets = uncheckedDataSets.stream().map(AbstractDataSet::getName).collect(Collectors.toSet());
EMStyleOptions options = createStyleOptions(panel.getNetworkView());
boolean pubReady = panel.getPublicationReadyCheck().isSelected();
ViewParams params = new ViewParams(suid, cuttofParam, pVal, qVal, sCoeff, filteredDataSets, options.getChartOptions(), pubReady);
map.put(suid, params);
});
return map;
}
Aggregations