PieSeries pieseries = (PieSeries) PieSeriesImpl.create( ); pieseries.setExplosion( 10 ); pieseries.getLeaderLineAttributes( ).setVisible( true ); pieseries.getLeaderLineAttributes( ) .setColor( ColorDefinitionImpl.BLACK( ) ); pieseries.setLeaderLineStyle( LeaderLineStyle.STRETCH_TO_SIDE_LITERAL );
PieSeries pieseries = (PieSeries) ChartCacheManager.getInstance( ) .findSeries( PieSeriesImpl.class.getName( ), seriesIndex ); if ( pieseries == null ) { pieseries = (PieSeries) PieSeriesImpl.create( ); pieseries.setExplosion( 10 ); }
	private Series getConvertedSeries( Series series )	{		// Do not convert base series		if ( series.getClass( )				.getName( )				.equals( "org.eclipse.birt.chart.model.component.impl.SeriesImpl" ) ) //$NON-NLS-1$		{			return series;		}		PieSeries pieseries = (PieSeries) PieSeriesImpl.create( );		pieseries.setExplosion( 10 );		pieseries.getLeaderLineAttributes( ).setVisible( true );		pieseries.getLeaderLineAttributes( )				.setColor( ColorDefinitionImpl.BLACK( ) );		pieseries.setLeaderLineStyle( LeaderLineStyle.STRETCH_TO_SIDE_LITERAL );		// Copy generic series properties		ChartUIUtil.copyGeneralSeriesAttributes( series, pieseries );		// Copy series specific properties		if ( series instanceof LineSeries )		{			pieseries.setLeaderLineAttributes( ( (LineSeries) series ).getLineAttributes( ) );		}		else if ( series instanceof StockSeries )		{			pieseries.setLeaderLineAttributes( ( (StockSeries) series ).getLineAttributes( ) );		}		return pieseries;	}