/*******************************************************************************
 * Copyright (c) 2004 Actuate Corporation.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *  Actuate Corporation  - initial API and implementation
 *******************************************************************************/

package org.eclipse.birt.chart.ui.swt.interfaces;

import org.eclipse.birt.chart.model.data.SeriesDefinition;
import org.eclipse.birt.chart.ui.swt.wizard.ChartWizardContext;
import org.eclipse.swt.widgets.Composite;

/**
 * 
 */

public interface ISelectDataCustomizeUI
{

	static final int ORTHOGONAL_SERIES = 1;
	static final int GROUPING_SERIES = 2;

	/**
	 * Creates left binding area
	 * 
	 * @param parent
	 *            composite parent
	 */
	void createLeftBindingArea( Composite parent );

	void createRightBindingArea( Composite parent );

	void createBottomBindingArea( Composite parent );

	void refreshLeftBindingArea( );

	void refreshRightBindingArea( );

	void refreshBottomBindingArea( );

	void selectLeftBindingArea( boolean selected, Object data );

	void selectRightBindingArea( boolean selected, Object data );

	void selectBottomBindingArea( boolean selected, Object data );

	/**
	 * Initializes all required resource.
	 * 
	 */
	void init( );

	/**
	 * Disposes all resources.
	 * 
	 */
	void dispose( );

	/**
	 * 
	 * @param areaType
	 *            <code>ORTHOGONAL_SERIES</code>,
	 *            <code>GROUPING_SERIES</code>
	 * @param seriesdefinition
	 * @param context
	 * @param sTitle
	 * @return UI component
	 */
	ISelectDataComponent getAreaComponent( int areaType,
			SeriesDefinition seriesdefinition, ChartWizardContext context,
			String sTitle );

	/**
	 * Gets custom preview table which is used for data preview
	 * 
	 * @return custom preview table
	 */
	Object getCustomPreviewTable( );

	void layoutAll( );

	/**
	 * Gets current selected series index of each axis.
	 * 
	 * @return array of current selected series index
	 */
	int[] getSeriesIndex( );

	/**
	 * Sets current selected series index of each axis.
	 * 
	 * @param seriesIndex
	 *            array of current selected series index
	 */
	void setSeriesIndex( int[] seriesIndex );
}
