switch (type) {
case SCAN_1D:
config = new Config1DImpl();
config.setScanAddOn(new ScanAddOnImp());
config.getScanAddOn().setDisplay(new DisplayImpl());
((IConfig1D) config).setDimensionX(new Dimension1DImpl());
// Creates one range for a new 1D config.
IRange1D range1DToAdd = new Range1DImpl();
range1DToAdd.setDimension(((IConfig1D) config).getDimensionX());
range1DToAdd.setIntegrationTime(1.0);
range1DToAdd.setStepsNumber(1);