if (series.getDataDefinition().size() != 4) {  stockseries.getDataDefinition().add(series.getDataDefinition().get(0));  stockseries.getDataDefinition().add(series.getDataDefinition().get(0));  stockseries.getDataDefinition().add(series.getDataDefinition().get(0));  stockseries.getDataDefinition().add(series.getDataDefinition().get(0)); }
    private Series getConvertedSeries(Series series)    {        // Do not convert base series        if (series.getClass().getName().equals("org.eclipse.birt.chart.model.component.impl.SeriesImpl"))        {            return series;        }        StockSeries stockseries = (StockSeries) StockSeriesImpl.create();        stockseries.getLineAttributes().setVisible(true);        stockseries.getLineAttributes().setColor(ColorDefinitionImpl.BLACK());        // Copy generic series properties        stockseries.setLabel(series.getLabel());        if (series.getLabelPosition().equals(Position.INSIDE_LITERAL)            || series.getLabelPosition().equals(Position.OUTSIDE_LITERAL))        {            stockseries.setLabelPosition(series.getLabelPosition());        }        else        {            stockseries.setLabelPosition(Position.OUTSIDE_LITERAL);        }        stockseries.setVisible(series.isVisible());        if (series.eIsSet(ComponentPackage.eINSTANCE.getSeries_Triggers()))        {            stockseries.getTriggers().addAll(series.getTriggers());        }        if (series.eIsSet(ComponentPackage.eINSTANCE.getSeries_DataPoint()))        {            stockseries.setDataPoint(series.getDataPoint());        }        if (series.eIsSet(ComponentPackage.eINSTANCE.getSeries_DataDefinition()))        {            stockseries.getDataDefinition().addAll(series.getDataDefinition());        }        // Copy series specific properties        if (series instanceof BarSeries)        {            stockseries.getLineAttributes().setColor(((BarSeries) series).getRiserOutline());        }        else if (series instanceof LineSeries)        {            stockseries.setLineAttributes(((LineSeries) series).getLineAttributes());        }        return stockseries;    }