use y1/y2 axis definitions

This commit is contained in:
2020-02-09 20:14:13 +01:00
parent 859491e99e
commit 57d016245c
20 changed files with 178 additions and 104 deletions

View File

@@ -4,14 +4,12 @@ import java.util.List;
import org.lucares.pdb.plot.api.Aggregate;
import org.lucares.pdb.plot.api.AggregateHandlerCollection;
import org.lucares.pdb.plot.api.AxisScale;
import org.lucares.pdb.plot.api.BarChartHandler;
import org.lucares.pdb.plot.api.CumulativeDistributionHandler;
import org.lucares.pdb.plot.api.HistogramHandler;
import org.lucares.pdb.plot.api.ParallelRequestsAggregate;
import org.lucares.pdb.plot.api.PlotSettings;
import org.lucares.pdb.plot.api.ScatterAggregateHandler;
import org.lucares.pdb.plot.api.TimeRangeUnit;
import org.lucares.pdb.plot.api.YAxisDefinition;
import org.lucares.pdbui.domain.PlotRequest;
@@ -69,12 +67,12 @@ class PlotSettingsTransformer {
aggregateHandlerCollection.updateAxisForHandlers();
// Note: this check is incomplete -> implement the todo and remove this
if (y1.getRangeUnit() == TimeRangeUnit.AUTOMATIC && y1.getAxisScale() == AxisScale.LINEAR) {
// TODO need a second ScatterAggregateHandler for YRangeUnit() ==
// TimeRangeUnitInternal.AUTOMATIC
throw new UnsupportedOperationException(
"linear axis with automatic y range does not work, use logarthmic y-axis, or define a y-axis range");
}
// if (y1.getRangeUnit() == RangeUnit.AUTOMATIC_TIME && y1.getAxisScale() == AxisScale.LINEAR) {
// // TODO need a second ScatterAggregateHandler for YRangeUnit() ==
// // TimeRangeUnitInternal.AUTOMATIC
// throw new UnsupportedOperationException(
// "linear axis with automatic y range does not work, use logarthmic y-axis, or define a y-axis range");
// }
return aggregateHandlerCollection;
}