public static void collectExpressions(XYDataset dataset, JRExpressionCollector collector) { collector.collect(dataset); XYSeries[] xySeries = dataset.getSeries(); if (xySeries != null && xySeries.length > 0) { JRExpressionCollector seriesCollector = collector.getCollector(dataset); for(int i = 0; i < xySeries.length; i++) { seriesCollector.addExpression(xySeries[i].getSeriesExpression()); seriesCollector.addExpression(xySeries[i].getXValueExpression()); seriesCollector.addExpression(xySeries[i].getYValueExpression()); seriesCollector.addExpression(xySeries[i].getColorExpression()); } } }
public static void collectExpressions(SpiderDataset dataset, JRExpressionCollector collector) { if(dataset != null) { collector.collect(dataset); JRCategorySeries[] categorySeries = dataset.getSeries(); if (categorySeries != null && categorySeries.length > 0) { JRExpressionCollector seriesCollector = collector.getCollector(dataset); for(int j = 0; j < categorySeries.length; j++) { seriesCollector.addExpression(categorySeries[j].getSeriesExpression()); seriesCollector.addExpression(categorySeries[j].getCategoryExpression()); seriesCollector.addExpression(categorySeries[j].getValueExpression()); seriesCollector.addExpression(categorySeries[j].getLabelExpression()); seriesCollector.collectHyperlink(categorySeries[j].getItemHyperlink()); } } } }
@Override public void collectExpressions(PartComponent component, JRExpressionCollector collector) { SubreportPartComponent subreport = (SubreportPartComponent) component; collector.addExpression(subreport.getParametersMapExpression()); JRSubreportParameter[] parameters = subreport.getParameters(); if (parameters != null && parameters.length > 0) { for(int j = 0; j < parameters.length; j++) { collector.addExpression(parameters[j].getExpression()); } } collector.addExpression(subreport.getExpression()); }
@Override public void collectExpressions(Component component, JRExpressionCollector collector) { ListComponent listComponent = (ListComponent) component; JRDatasetRun datasetRun = listComponent.getDatasetRun(); collector.collect(datasetRun); JRExpressionCollector datasetCollector = collector.getDatasetCollector( datasetRun.getDatasetName()); JRElement[] elements = listComponent.getContents().getElements(); if (elements != null) { for (int i = 0; i < elements.length; i++) { elements[i].collectExpressions(datasetCollector); } } }
@Override public void collectExpressions(Component component, JRExpressionCollector collector) { BarbecueComponent barcode = (BarbecueComponent) component; collector.addExpression(barcode.getCodeExpression()); collector.addExpression(barcode.getApplicationIdentifierExpression()); }
@Override public void collectExpressions(Component component, JRExpressionCollector collector) { MapComponent map = (MapComponent) component; collector.addExpression(map.getLatitudeExpression()); collector.addExpression(map.getLongitudeExpression()); collector.addExpression(map.getAddressExpression()); collector.addExpression(map.getZoomExpression()); collector.addExpression(map.getLanguageExpression()); List<ItemData> markerDataList = map.getMarkerDataList(); if(markerDataList != null && markerDataList.size() > 0) { for(ItemData markerData : markerDataList){ ItemCompiler.collectExpressions(markerData, collector); } } List<ItemData> pathStyleList = map.getPathStyleList(); if(pathStyleList != null && pathStyleList.size() > 0) { for(ItemData pathStyle : pathStyleList){ ItemCompiler.collectExpressions(pathStyle, collector); } } List<ItemData> pathDataList = map.getPathDataList(); if(pathDataList != null && pathDataList.size() > 0) { for(ItemData pathData : pathDataList){ ItemCompiler.collectExpressions(pathData, collector); } } }
public static void collectExpressions(BarDataset dataset, JRExpressionCollector collector) { collector.collect(dataset); JRExpressionCollector datasetCollector = collector.getCollector(dataset); for (Iterator<BarSeries> it = dataset.getSeries().iterator(); it.hasNext();) { BarSeries series = it.next(); datasetCollector.addExpression(series.getSeriesExpression()); datasetCollector.addExpression(series.getCategoryExpression()); datasetCollector.addExpression(series.getValueExpression()); } }
/** * Adds all the expression used by this plot with the specified collector. * All collected expression that are also registered with a factory will * be included with the report is compiled. * * @param collector the expression collector to use */ @Override public void collectExpressions(JRExpressionCollector collector) { Iterator<JRChartAxis> iter = axes.iterator(); while (iter.hasNext()) { JRChartAxis axis = iter.next(); collector.collect(axis.getChart()); } }
public static void collectExpressions(SpiderPlot spiderPlot, JRExpressionCollector collector) { if(spiderPlot != null) { collector.addExpression(spiderPlot.getMaxValueExpression()); } }
private JRCompilationUnit createCompileUnit(JasperDesign jasperDesign, JRDesignDataset dataset, JRExpressionCollector expressionCollector, File saveSourceDir, String nameSuffix) throws JRException { String unitName = JRAbstractCompiler.getUnitName(jasperDesign, dataset, nameSuffix); JRSourceCompileTask sourceTask = new JRSourceCompileTask(jasperDesign, dataset, expressionCollector, unitName); JRCompilationSourceCode sourceCode = generateSourceCode(sourceTask); File sourceFile = getSourceFile(saveSourceDir, unitName, sourceCode); return new JRCompilationUnit(unitName, sourceCode, sourceFile, expressionCollector.getExpressions(dataset), sourceTask); }
@Override public void collectExpressions(Component component, JRExpressionCollector collector) { SpiderChartComponent chart = (SpiderChartComponent) component; collectExpressions(chart.getChartSettings(), collector); collectExpressions((SpiderDataset)chart.getDataset(), collector); collectExpressions((SpiderPlot)chart.getPlot(), collector); }
public static void collectExpressions(ChartSettings chart, JRExpressionCollector collector) { if(chart != null) { collector.addExpression(chart.getTitleExpression()); collector.addExpression(chart.getSubtitleExpression()); collector.addExpression(chart.getAnchorNameExpression()); collector.addExpression(chart.getHyperlinkReferenceExpression()); collector.addExpression(chart.getHyperlinkWhenExpression()); collector.addExpression(chart.getHyperlinkAnchorExpression()); collector.addExpression(chart.getHyperlinkPageExpression()); collector.addExpression(chart.getHyperlinkTooltipExpression()); JRHyperlinkParameter[] hyperlinkParameters = chart.getHyperlinkParameters(); if (hyperlinkParameters != null) { for (int i = 0; i < hyperlinkParameters.length; i++) { JRHyperlinkParameter parameter = hyperlinkParameters[i]; if (parameter != null) { collector.addExpression(parameter.getValueExpression()); } } } } }
/** * */ protected JRVerifier( JasperReportsContext jasperReportsContext, JasperDesign jasperDesign, JRExpressionCollector expressionCollector ) { this.jasperReportsContext = jasperReportsContext; this.jasperDesign = jasperDesign; this.sectionType = jasperDesign.getSectionType() == null ? SectionTypeEnum.BAND : jasperDesign.getSectionType(); brokenRules = new ArrayList<JRValidationFault>(); if (expressionCollector != null) { this.expressionCollector = expressionCollector; } else { this.expressionCollector = JRExpressionCollector.collector(jasperReportsContext, jasperDesign); } allowElementNegativeWidth = JRPropertiesUtil.getInstance(jasperReportsContext).getBooleanProperty(jasperDesign, PROPERTY_ALLOW_ELEMENT_NEGATIVE_WIDTH, false); allowElementNegativeX = JRPropertiesUtil.getInstance(jasperReportsContext).getBooleanProperty(jasperDesign, PROPERTY_ALLOW_ELEMENT_NEGATIVE_X, true); allowElementNegativeY = JRPropertiesUtil.getInstance(jasperReportsContext).getBooleanProperty(jasperDesign, PROPERTY_ALLOW_ELEMENT_NEGATIVE_Y, true); }
public static void collectExpressions(ItemData data, JRExpressionCollector collector) { if (data != null) { JRExpressionCollector datasetCollector = collector; JRElementDataset dataset = data.getDataset(); JRDatasetRun datasetRun = dataset == null ? null : dataset.getDatasetRun(); if (datasetRun != null) { collector.collect(datasetRun); datasetCollector = collector.getDatasetCollector(datasetRun.getDatasetName()); } List<Item> items = data.getItems(); if (items != null && !items.isEmpty()) { for(Item item : items) { List<ItemProperty> itemProperties = item.getProperties(); if(itemProperties != null) { for(ItemProperty property : itemProperties) { datasetCollector.addExpression(property.getValueExpression()); } } } } } }
@Override public void collectExpressions(Component component, JRExpressionCollector collector) { IconLabelComponent iconLabelComponent = (IconLabelComponent) component; collector.collect(iconLabelComponent.getLabelTextField()); collector.collect(iconLabelComponent.getIconTextField()); }
public JRReportTemplate(JRReport report, String compilerClass, Serializable compileData, JRExpressionCollector expressionCollector, String compileNameSuffix) { super(report, compilerClass, compileData, expressionCollector, compileNameSuffix); }
@Override public void collectExpressions(JRExpressionCollector collector) { XYChartCompiler.collectExpressions(dataset, collector); }
@Override public void collectExpressions(JRExpressionCollector collector) { XYChartCompiler.collectExpressions(this, collector); }
@Override public void collectExpressions(JRExpressionCollector collector) { }
public void collectExpressions(JRExpressionCollector collector) { BarChartCompiler.collectExpressions(dataset, collector); }
public void collectExpressions(Component component, JRExpressionCollector collector) { PieChartComponent chart = (PieChartComponent) component; collector.addExpression(chart.getTitleExpression()); collectExpressions(chart.getDataset(), collector); }
@Override public void collectExpressions(JRExpressionCollector collector) { SpiderChartCompiler.collectExpressions(this, collector); }
public void collectExpressions(JRExpressionCollector collector) { PieChartCompiler.collectExpressions(this, collector); }
@Override public void collectExpressions(JRExpressionCollector collector) { collector.collect(this); }
public void collectExpressions(Component component, JRExpressionCollector collector) { BarChartComponent chart = (BarChartComponent) component; collector.addExpression(chart.getTitleExpression()); collectExpressions(chart.getDataset(), collector); }
public void collectExpressions(JRExpressionCollector collector) { BarChartCompiler.collectExpressions(this, collector); }
public void collectExpressions(JRExpressionCollector collector) { PieChartCompiler.collectExpressions(dataset, collector); }
@Override public void collectExpressions(Component component, JRExpressionCollector collector) { HtmlComponent htmlComponent = (HtmlComponent) component; collector.addExpression(htmlComponent.getHtmlContentExpression()); }
/** * */ public void collectExpressions(JRExpressionCollector collector) { SpiderChartCompiler.collectExpressions(this, collector); }
public void collectExpressions(JRExpressionCollector collector) { SpiderChartCompiler.collectExpressions(this, collector); }