blob: f1c2787b5b778355707a35a6f89daa73554ed087 [file] [log] [blame]
/*
*
* Copyright (c) 2011 - 2017 - Loetz GmbH & Co KG, 69115 Heidelberg, Germany
*
* 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
*
* Initial contribution:
* Loetz GmbH & Co. KG
*
*/
package org.eclipse.osbp.ui.api.datamart;
import org.eclipse.osbp.runtime.common.event.EventDispatcherEvent;
import org.eclipse.osbp.ui.api.layout.IViewLayoutManager;
/**
* The Interface IDatamartFilterGenerator.
*/
public interface IDatamartFilterGenerator {
/** The Constant MULTISELECTION_ROWS. */
public static final int MULTISELECTION_ROWS=10;
/** The Constant SHOW_CAPTION. */
public static final boolean SHOW_CAPTION=false;
/**
* Creates the UI filters.
*
* @param layoutManager the layout manager
* @return true, if successful
*/
boolean createUIFilters(IViewLayoutManager layoutManager);
/**
* Select item.
*
* @param filterID the filter ID
* @param selection the selection
*/
void selectItem(String filterID, String selection);
/**
* Select item.
*
* @param event the event
* @param byId, if true also id events are processed
* @return true, if selection must trigger a dataRefresh
*/
boolean selectItem(EventDispatcherEvent event, boolean byId);
/**
* Reset item.
*
* @param filterID the filter ID
*/
void resetItem(String filterID);
/**
* Update filter.
*/
void updateFilter();
/**
* Adds the filter change listener.
*
* @param listener the listener
*/
void addFilterChangeListener(FilterChangeListener listener);
/**
* Removes the change listener.
*
* @param listener the listener
*/
void removeFilterChangeListener(FilterChangeListener listener);
/**
* The listener interface for receiving filterChange events.
* The class that is interested in processing a filterChange
* event implements this interface, and the object created
* with that class is registered with a component using the
* component's <code>addFilterChangeListener<code> method. When
* the filterChange event occurs, that object's appropriate
* method is invoked.
*
* @see FilterChangeEvent
*/
public interface FilterChangeListener {
/**
* Filter changed. Notify all listeners.
*
* @param changedFilter the changed filter
*/
void filterChanged(DatamartFilter changedFilter);
}
}