use of org.talend.dq.indicators.preview.EIndicatorChartType in project tdq-studio-se by Talend.
the class ColumnSetAnalysisDetailsPage method createAllMatch.
private void createAllMatch(final Composite composite) {
List<IndicatorUnit> units = new ArrayList<IndicatorUnit>();
units.add(new ColumnSetIndicatorUnit(IndicatorEnum.AllMatchIndicatorEnum, allMatchIndicator));
EIndicatorChartType matchingType = EIndicatorChartType.PATTERN_MATCHING;
IChartTypeStates chartTypeState = ChartTypeStatesFactory.getChartState(matchingType, units);
Object chart = chartTypeState.getChart();
TOPChartUtils.getInstance().decorateChart(chart, false);
if (chart != null) {
TOPChartUtils.getInstance().createChartComposite(composite, SWT.NONE, chart, true);
}
}
use of org.talend.dq.indicators.preview.EIndicatorChartType in project tdq-studio-se by Talend.
the class ColumnSetAnalysisResultPage method createAllMatchPart.
private Section createAllMatchPart(Composite parentComp, String title, AllMatchIndicator matchIndicator) {
Section section = createSection(form, parentComp, title, null);
section.setLayoutData(new GridData(GridData.FILL_BOTH));
Composite sectionClient = toolkit.createComposite(section);
sectionClient.setLayout(new GridLayout(2, false));
sectionClient.setLayoutData(new GridData(GridData.FILL_BOTH));
GridDataFactory.fillDefaults().align(SWT.FILL, SWT.TOP).applyTo(sectionClient);
List<IndicatorUnit> units = new ArrayList<IndicatorUnit>();
units.add(new ColumnSetIndicatorUnit(IndicatorEnum.AllMatchIndicatorEnum, allMatchIndicator));
EIndicatorChartType matchingType = EIndicatorChartType.PATTERN_MATCHING;
ITableTypeStates tableTypeState = TableTypeStatesFactory.getInstance().getTableState(matchingType, units);
TableWithData chartData = new TableWithData(matchingType, tableTypeState.getDataEntity());
TableViewer tableviewer = tableTypeState.getTableForm(sectionClient);
tableviewer.setInput(chartData);
// MOD qiongli feature 19192.
if (masterPage.getCurrentModelElement().getParameters().isStoreData()) {
ChartTableFactory.addMenuAndTip(tableviewer, tableTypeState.getDataExplorer(), masterPage.getCurrentModelElement());
} else {
TableUtils.addTooltipForTable(tableviewer.getTable());
TableUtils.addActionTooltip(tableviewer.getTable());
}
if (canShowChartForResultPage()) {
IChartTypeStates chartTypeState = ChartTypeStatesFactory.getChartState(matchingType, units);
Object chart = chartTypeState.getChart();
TOPChartUtils.getInstance().decorateChart(chart, false);
if (chart != null) {
TOPChartUtils.getInstance().createChartComposite(sectionClient, SWT.NONE, chart, true);
}
}
section.setClient(sectionClient);
return section;
}
use of org.talend.dq.indicators.preview.EIndicatorChartType in project tdq-studio-se by Talend.
the class ResultPaginationInfo method createResultDataComposite.
private void createResultDataComposite(Composite comp, ModelElementIndicator modelElementIndicator) {
if (modelElementIndicator.getIndicators().length != 0) {
Map<EIndicatorChartType, List<IndicatorUnit>> indicatorComposite = CompositeIndicator.getInstance().getIndicatorComposite(modelElementIndicator);
for (EIndicatorChartType chartType : indicatorComposite.keySet()) {
List<IndicatorUnit> units = indicatorComposite.get(chartType);
if (!units.isEmpty()) {
if (chartType == EIndicatorChartType.UDI_FREQUENCY) {
for (IndicatorUnit unit : units) {
List<IndicatorUnit> specialUnit = new ArrayList<IndicatorUnit>();
specialUnit.add(unit);
createChart(comp, chartType, specialUnit);
}
} else {
createChart(comp, chartType, units);
}
}
}
}
}
Aggregations