public class DynamicReportBuilder extends Object
Modifier and Type | Field and Description |
---|---|
protected ArrayList |
autoTexts |
protected boolean |
built
DynamicReportBuilder cannot be used twice since this produced undesired
results on the generated DynamicReport Object.
|
protected ArrayList |
concatenatedReports |
protected ArrayList |
globalFooterCrosstabs |
protected ArrayList |
globalHeaderCrosstabs |
protected DJGroup |
globalVariablesGroup |
protected Map |
groupFooterSubreports |
protected Map |
groupHeaderSubreports |
protected DynamicReportOptions |
options |
protected DynamicReport |
report |
Constructor and Description |
---|
DynamicReportBuilder() |
Modifier and Type | Method and Description |
---|---|
DynamicReportBuilder |
addAutoText(AutoText text) |
DynamicReportBuilder |
addAutoText(byte type,
byte position,
byte alignment)
Adds an autotext to the Report, this are common texts such us "Page X/Y", "Created on 07/25/2007", etc.
|
DynamicReportBuilder |
addAutoText(byte type,
byte position,
byte alignment,
byte pattern)
Adds an autotext to the Report, this are common texts such us "Page X/Y", "Created on 07/25/2007", etc.
|
DynamicReportBuilder |
addAutoText(byte type,
byte position,
byte alignment,
byte pattern,
int width,
int width2)
Adds an autotext to the Report, this are common texts such us "Page X/Y", "Created on 07/25/2007", etc.
|
DynamicReportBuilder |
addAutoText(byte type,
byte position,
byte alignment,
int width,
int width2)
Adds an autotext to the Report, this are common texts such us "Page X/Y", "Created on 07/25/2007", etc.
|
DynamicReportBuilder |
addAutoText(byte type,
byte position,
byte alignment,
int width,
int width2,
Style style) |
DynamicReportBuilder |
addAutoText(String message,
byte position,
byte alignment)
Adds a custom fixed message (literal) in header or footer.
|
DynamicReportBuilder |
addAutoText(String message,
byte position,
byte alignment,
int width)
Adds a custom fixed message (literal) in header or footer.
|
DynamicReportBuilder |
addAutoText(String message,
byte position,
byte alignment,
int width,
Style style) |
DynamicReportBuilder |
addChart(DJChart chart)
Deprecated.
|
DynamicReportBuilder |
addChart(DJChart djChart)
Registers a field that is not necesary bound to a column, it can be used in a
custom expression
|
DynamicReportBuilder |
addColumn(AbstractColumn column) |
DynamicReportBuilder |
addConcatenatedReport(DynamicReport dynamicReport,
LayoutManager layoutManager,
String dataSourcePath,
int dataSourceOrigin,
int dataSourceType) |
DynamicReportBuilder |
addConcatenatedReport(DynamicReport dynamicReport,
LayoutManager layoutManager,
String dataSourcePath,
int dataSourceOrigin,
int dataSourceType,
boolean startOnNewPage) |
DynamicReportBuilder |
addConcatenatedReport(net.sf.jasperreports.engine.JasperReport jasperReport,
String dataSourcePath,
int dataSourceOrigin,
int dataSourceType) |
DynamicReportBuilder |
addConcatenatedReport(net.sf.jasperreports.engine.JasperReport jasperReport,
String dataSourcePath,
int dataSourceOrigin,
int dataSourceType,
boolean startOnNewPage) |
DynamicReportBuilder |
addConcatenatedReport(Subreport subreport)
All concatenated reports are shown in the same order they are inserted
|
DynamicReportBuilder |
addField(ColumnProperty columnProperty)
Registers a field that is not necesary bound to a column, it can be used in a
custom expression
|
DynamicReportBuilder |
addField(String name,
Class clazz) |
DynamicReportBuilder |
addField(String name,
String className)
Registers a field that is not necesary bound to a column, it can be used in a
custom expression
|
DynamicReportBuilder |
addFirstPageFooterImageBanner(String path,
Integer width,
Integer height,
byte align) |
DynamicReportBuilder |
addFirstPageImageBanner(String path,
Integer width,
Integer height,
byte align) |
DynamicReportBuilder |
addFirstPageImageBanner(String path,
Integer width,
Integer height,
byte align,
ImageScaleMode scaleMode) |
DynamicReportBuilder |
addFont(String fontName,
Font font) |
DynamicReportBuilder |
addFooterCrosstab(DJCrosstab cross)
Adds a crosstab in the footer of the report (at the end of all data)
|
DynamicReportBuilder |
addFooterImageBanner(String path,
Integer width,
Integer height,
byte align,
ImageScaleMode scaleMode) |
DynamicReportBuilder |
addGlobalColumnVariable(String position,
AbstractColumn column,
CustomExpression valueExpression) |
DynamicReportBuilder |
addGlobalColumnVariable(String position,
AbstractColumn column,
CustomExpression valueExpression,
Style style) |
DynamicReportBuilder |
addGlobalColumnVariable(String position,
AbstractColumn col,
DJCalculation op) |
DynamicReportBuilder |
addGlobalColumnVariable(String position,
AbstractColumn col,
DJCalculation op,
Style style) |
DynamicReportBuilder |
addGlobalColumnVariable(String position,
AbstractColumn col,
DJCalculation op,
Style style,
DJValueFormatter valueFormatter) |
DynamicReportBuilder |
addGlobalColumnVariable(String position,
DJGroupVariable variable) |
DynamicReportBuilder |
addGlobalFooterVariable(AbstractColumn column,
CustomExpression valueExpression) |
DynamicReportBuilder |
addGlobalFooterVariable(AbstractColumn column,
CustomExpression valueExpression,
Style style) |
DynamicReportBuilder |
addGlobalFooterVariable(AbstractColumn col,
DJCalculation op) |
DynamicReportBuilder |
addGlobalFooterVariable(AbstractColumn col,
DJCalculation op,
Style style) |
DynamicReportBuilder |
addGlobalFooterVariable(AbstractColumn col,
DJCalculation op,
Style style,
DJValueFormatter valueFormatter) |
DynamicReportBuilder |
addGlobalFooterVariable(DJGroupVariable variable) |
DynamicReportBuilder |
addGlobalHeaderVariable(AbstractColumn column,
CustomExpression valueExpression) |
DynamicReportBuilder |
addGlobalHeaderVariable(AbstractColumn column,
CustomExpression valueExpression,
Style style) |
DynamicReportBuilder |
addGlobalHeaderVariable(AbstractColumn col,
DJCalculation op) |
DynamicReportBuilder |
addGlobalHeaderVariable(AbstractColumn col,
DJCalculation op,
Style style) |
DynamicReportBuilder |
addGlobalHeaderVariable(AbstractColumn col,
DJCalculation op,
Style style,
DJValueFormatter valueFormatter) |
DynamicReportBuilder |
addGlobalHeaderVariable(DJGroupVariable variable) |
DynamicReportBuilder |
addGlobalVariable(String name,
AbstractColumn col,
DJCalculation op)
For variable registration only (can bee later referenced in custom expression)
|
DynamicReportBuilder |
addGlobalVariable(String name,
ColumnProperty prop,
DJCalculation op) |
DynamicReportBuilder |
addGlobalVariable(String name,
String property,
String className,
DJCalculation op) |
DynamicReportBuilder |
addGroup(DJGroup group) |
DynamicReportBuilder |
addHeaderCrosstab(DJCrosstab cross)
Adds a crosstab in the header, before the the data
|
DynamicReportBuilder |
addImageBanner(String path,
Integer width,
Integer height,
byte align) |
DynamicReportBuilder |
addImageBanner(String path,
Integer width,
Integer height,
byte align,
ImageScaleMode scaleMode) |
DynamicReportBuilder |
addParameter(String name,
String className) |
DynamicReportBuilder |
addResourceBundle(String resourceBundle)
Deprecated.
|
DynamicReportBuilder |
addStyle(Style style)
You can register styles object for later reference them directly.
|
DynamicReportBuilder |
addSubreportInGroup(String position,
int groupNumber,
DynamicReport dynamicReport,
LayoutManager layoutManager,
String dataSourcePath,
int dataSourceOrigin,
int dataSourceType,
SubreportParameter[] params) |
DynamicReportBuilder |
addSubreportInGroup(String position,
int groupNumber,
DynamicReport dynamicReport,
LayoutManager layoutManager,
String dataSourcePath,
int dataSourceOrigin,
int dataSourceType,
SubreportParameter[] params,
boolean startInNewPage,
boolean fitParent) |
DynamicReportBuilder |
addSubreportInGroupFooter(int groupNumber,
DynamicReport dynamicReport,
LayoutManager layoutManager,
String dataSourcePath,
int dataSourceOrigin,
int dataSourceType) |
DynamicReportBuilder |
addSubreportInGroupFooter(int groupNumber,
DynamicReport dynamicReport,
LayoutManager layoutManager,
String dataSourcePath,
int dataSourceOrigin,
int dataSourceType,
SubreportParameter[] params) |
DynamicReportBuilder |
addSubreportInGroupFooter(int groupNumber,
DynamicReport dynamicReport,
LayoutManager layoutManager,
String dataSourcePath,
int dataSourceOrigin,
int dataSourceType,
SubreportParameter[] params,
boolean startInNewPage) |
DynamicReportBuilder |
addSubreportInGroupFooter(int groupNumber,
DynamicReport dynamicReport,
LayoutManager layoutManager,
String dataSourcePath,
int dataSourceOrigin,
int dataSourceType,
SubreportParameter[] params,
boolean startInNewPage,
boolean fitParent) |
DynamicReportBuilder |
addSubreportInGroupFooter(int groupNumber,
String pathToSubreport,
String dataSourcePath,
int dataSourceOrigin,
int dataSourceType) |
DynamicReportBuilder |
addSubreportInGroupFooter(int groupNumber,
String pathToSubreport,
String dataSourcePath,
int dataSourceOrigin,
int dataSourceType,
boolean startInNewPage) |
DynamicReportBuilder |
addSubreportInGroupFooter(int groupNumber,
Subreport subreport)
Adds in the group (starts with 1) "groupNumber" a subreport in the footer band
|
DynamicReportBuilder |
addSubreportInGroupHeader(int groupNumber,
DynamicReport dynamicReport,
LayoutManager layoutManager,
String dataSourcePath,
int dataSourceOrigin,
int dataSourceType) |
DynamicReportBuilder |
addSubreportInGroupHeader(int groupNumber,
DynamicReport dynamicReport,
LayoutManager layoutManager,
String dataSourcePath,
int dataSourceOrigin,
int dataSourceType,
SubreportParameter[] params) |
DynamicReportBuilder |
addSubreportInGroupHeader(int groupNumber,
DynamicReport dynamicReport,
LayoutManager layoutManager,
String dataSourcePath,
int dataSourceOrigin,
int dataSourceType,
SubreportParameter[] params,
boolean startInNewPage) |
DynamicReportBuilder |
addSubreportInGroupHeader(int groupNumber,
DynamicReport dynamicReport,
LayoutManager layoutManager,
String dataSourcePath,
int dataSourceOrigin,
int dataSourceType,
SubreportParameter[] params,
boolean startInNewPage,
boolean fitParent) |
DynamicReportBuilder |
addSubreportInGroupHeader(int groupNumber,
String pathToSubreport,
String dataSourcePath,
int dataSourceOrigin,
int dataSourceType) |
DynamicReportBuilder |
addSubreportInGroupHeader(int groupNumber,
Subreport subreport) |
protected void |
addSubreportsToGroups()
Because the groups are not created until we call the "build()" method, all the subreports that must go
inside a group are handled here.
|
DynamicReportBuilder |
addVariable(DJVariable var)
Use this to register variables manually.
|
DynamicReportBuilder |
addWatermark(DJWaterMark waterMark) |
DynamicReportBuilder |
addWatermark(String text) |
DynamicReportBuilder |
addWatermark(String text,
Font font,
Color color,
int angle) |
DynamicReport |
build()
Builds the DynamicReport object.
|
protected void |
concatenateReports()
Create dummy groups for each concatenated report, and in the footer of each group
adds the subreport.
|
AbstractColumn |
getColumn(int idx)
Returns the "idx" column, idx is 0 based
|
List |
getColumns()
returns an unmodifiable List of the columns so far
|
List |
getFields()
Returns registered fields so far.
|
DJGroup |
getGroup(int idx)
Returns the "idx" group, idx is 0 based
|
DynamicReportBuilder |
setAllowDetailSplit(boolean split)
If true and there is no room for a textfield at the end of a page in the detail band, it will be splitted and continued in
next page.
|
DynamicReportBuilder |
setBottomMargin(int margin) |
DynamicReportBuilder |
setBottomMargin(Integer margin) |
DynamicReportBuilder |
setColspan(int colNumber,
int colQuantity,
String colspanTitle)
Set a colspan in a group of columns.
|
DynamicReportBuilder |
setColspan(int colNumber,
int colQuantity,
String colspanTitle,
Style colspanStyle) |
DynamicReportBuilder |
setColumnSpace(int columSpace) |
DynamicReportBuilder |
setColumnSpace(Integer columSpace) |
DynamicReportBuilder |
setColumnsPerPage(int numColumns) |
DynamicReportBuilder |
setColumnsPerPage(Integer numColumns) |
DynamicReportBuilder |
setColumnsPerPage(Integer numColumns,
Integer columnSpace) |
DynamicReportBuilder |
setColumnsPerPage(int numColumns,
int columnSpace) |
DynamicReportBuilder |
setDefaultStyles(Style title,
Style subtitle,
Style columnHeader,
Style columDetail) |
DynamicReportBuilder |
setDetailHeight(int height) |
DynamicReportBuilder |
setDetailHeight(Integer height) |
DynamicReportBuilder |
setFooterHeight(int height)
Deprecated.
|
DynamicReportBuilder |
setFooterHeight(Integer height)
Deprecated.
|
DynamicReportBuilder |
setFooterVariablesHeight(int height) |
DynamicReportBuilder |
setFooterVariablesHeight(Integer height) |
DynamicReportBuilder |
setGlobalFooterVariableHeight(Integer height) |
DynamicReportBuilder |
setGlobalHeaderVariableHeight(Integer height) |
DynamicReportBuilder |
setGrandTotalLegend(String title) |
DynamicReportBuilder |
setGrandTotalLegendStyle(Style grandTotalStyle) |
DynamicReportBuilder |
setHeaderHeight(int height) |
DynamicReportBuilder |
setHeaderHeight(Integer height) |
DynamicReportBuilder |
setHeaderVariablesHeight(Integer height) |
DynamicReportBuilder |
setIgnorePagination(boolean bool)
When TRUE, no page break at all (useful for Excell)
Default is FALSE
|
DynamicReportBuilder |
setLanguage(String language)
Sets the language of the expressions used in the report
(can be one of java, groovy, or javascript).
|
DynamicReportBuilder |
setLeftMargin(int margin) |
DynamicReportBuilder |
setLeftMargin(Integer margin) |
DynamicReportBuilder |
setMargins(int top,
int bottom,
int left,
int right) |
DynamicReportBuilder |
setOddRowBackgroundStyle(Style oddRowBackgroundStyle) |
DynamicReportBuilder |
setPageSizeAndOrientation(Page page)
Defines the page size and orientation.
|
DynamicReportBuilder |
setPrintBackgroundOnOddRows(boolean printBackgroundOnOddRows) |
DynamicReportBuilder |
setPrintBackgroundOnOddRows(Boolean printBackgroundOnOddRows) |
DynamicReportBuilder |
setPrintColumnNames(boolean bool)
When FALSE, no column names are printed (in the header band)
|
DynamicReportBuilder |
setProperty(String name,
String value)
Adds a property to report design, this properties are mostly used by exporters
to know if any specific configuration is needed
|
DynamicReportBuilder |
setQuery(String text,
String language)
Adds main report query.
|
DynamicReportBuilder |
setReportLocale(Locale locale)
Adds the locale to use when filling the report.
|
DynamicReportBuilder |
setReportName(String reportName)
Sets the name of the report.
|
DynamicReportBuilder |
setResourceBundle(String resourceBundle) |
DynamicReportBuilder |
setRightMargin(int margin) |
DynamicReportBuilder |
setRightMargin(Integer margin) |
DynamicReportBuilder |
setShowDetailBand(boolean bool)
When false, no detail is shown.
|
DynamicReportBuilder |
setSubtitle(String subtitle) |
DynamicReportBuilder |
setSubtitleHeight(Integer height) |
DynamicReportBuilder |
setSubtitleStyle(Style subtitleStyle) |
DynamicReportBuilder |
setTemplateFile(String path)
The full path of a jrxml file, or the path in the classpath of a jrxml resource.
|
DynamicReportBuilder |
setTemplateFile(String path,
boolean importFields,
boolean importVariables,
boolean importParameters,
boolean importDatasets)
The full path of a jrxml file, or the path in the classpath of a jrxml resource.
|
DynamicReportBuilder |
setTitle(String title) |
DynamicReportBuilder |
setTitle(String title,
boolean isExpression) |
DynamicReportBuilder |
setTitleHeight(Integer height) |
DynamicReportBuilder |
setTitleIsJrExpression(boolean isExpression) |
DynamicReportBuilder |
setTitleStyle(Style titleStyle) |
DynamicReportBuilder |
setTopMargin(int margin) |
DynamicReportBuilder |
setTopMargin(Integer margin) |
DynamicReportBuilder |
setUseFullPageWidth(boolean useFullwidth) |
DynamicReportBuilder |
setUseFullPageWidth(Boolean useFullwidth) |
DynamicReportBuilder |
setWhenNoData(String text,
Style style)
Defines the text to show when the data source is empty.
|
DynamicReportBuilder |
setWhenNoData(String text,
Style style,
boolean showTitle,
boolean showColumnHeader)
Defines the text to show when the data source is empty.
|
DynamicReportBuilder |
setWhenNoDataAllSectionNoDetail() |
DynamicReportBuilder |
setWhenNoDataBlankPage() |
DynamicReportBuilder |
setWhenNoDataNoPages() |
DynamicReportBuilder |
setWhenNoDataShowNoDataSection() |
DynamicReportBuilder |
setWhenNoDataType(byte whenNoDataType)
Defines the behaviour when the datasource is empty.
|
DynamicReportBuilder |
setWhenResourceMissing(byte whenResourceMissing)
Defines what to show if a missing resource is referenced Possible values
are:
DJConstants.WHEN_RESOURCE_MISSING_TYPE_EMPTY: Leaves and empty field. |
DynamicReportBuilder |
setWhenResourceMissingLeaveEmptySpace() |
DynamicReportBuilder |
setWhenResourceMissingReturnNull() |
DynamicReportBuilder |
setWhenResourceMissingShowKey() |
DynamicReportBuilder |
setWhenResourceMissingThrowException() |
protected boolean built
protected DynamicReport report
protected DynamicReportOptions options
protected ArrayList globalFooterCrosstabs
protected ArrayList globalHeaderCrosstabs
protected ArrayList autoTexts
protected Map groupFooterSubreports
protected Map groupHeaderSubreports
protected DJGroup globalVariablesGroup
protected ArrayList concatenatedReports
public DynamicReportBuilder addAutoText(AutoText text)
public DynamicReportBuilder addAutoText(byte type, byte position, byte alignment, byte pattern)
ar.com.fdvs.dj.domain.AutoText
classtype
- One of these constants: position
- POSITION_HEADER or POSITION_FOOTERalignment
- pattern
- only for dates: public DynamicReportBuilder addAutoText(byte type, byte position, byte alignment, byte pattern, int width, int width2)
ar.com.fdvs.dj.domain.AutoText
classtype
- One of these constants: position
- POSITION_HEADER or POSITION_FOOTERalignment
- pattern
- only for dates: width
- with of the autotext. If autotext is of the type AUTOTEXT_PAGE_X_OF_Y or AUTOTEXT_PAGE_X_SLASH_Y then is the width of the first partwidth2
- If autotext is of the type AUTOTEXT_PAGE_X_OF_Y or AUTOTEXT_PAGE_X_SLASH_Y, this defines the width given to the "total page" variablepublic DynamicReportBuilder addAutoText(String message, byte position, byte alignment)
ar.com.fdvs.dj.domain.AutoText
class
message
- The text to showposition
- POSITION_HEADER or POSITION_FOOTERalignment
- public DynamicReportBuilder addAutoText(String message, byte position, byte alignment, int width)
ar.com.fdvs.dj.domain.AutoText
class
message
- The text to showposition
- POSITION_HEADER or POSITION_FOOTERalignment
- width
- the width of the messagepublic DynamicReportBuilder addAutoText(String message, byte position, byte alignment, int width, Style style)
public DynamicReportBuilder addAutoText(byte type, byte position, byte alignment, int width, int width2)
ar.com.fdvs.dj.domain.AutoText
classtype
- One of these constants: position
- POSITION_HEADER or POSITION_FOOTERalignment
- public DynamicReportBuilder addAutoText(byte type, byte position, byte alignment, int width, int width2, Style style)
public DynamicReportBuilder addAutoText(byte type, byte position, byte alignment)
ar.com.fdvs.dj.domain.AutoText
classtype
- One of these constants: position
- POSITION_HEADER or POSITION_FOOTERalignment
- public DynamicReport build()
protected void addSubreportsToGroups()
protected void concatenateReports()
public DynamicReportBuilder setTitle(String title)
public DynamicReportBuilder setTitleIsJrExpression(boolean isExpression)
public DynamicReportBuilder setReportName(String reportName)
reportName
- public DynamicReportBuilder setSubtitle(String subtitle)
public DynamicReportBuilder addColumn(AbstractColumn column)
public List getColumns()
public DynamicReportBuilder addGroup(DJGroup group)
public DynamicReportBuilder setHeaderHeight(Integer height)
public DynamicReportBuilder setHeaderHeight(int height)
public DynamicReportBuilder setFooterHeight(Integer height)
height
- public DynamicReportBuilder setFooterHeight(int height)
height
- public DynamicReportBuilder setFooterVariablesHeight(Integer height)
public DynamicReportBuilder setFooterVariablesHeight(int height)
public DynamicReportBuilder setHeaderVariablesHeight(Integer height)
public DynamicReportBuilder setDetailHeight(Integer height)
public DynamicReportBuilder setDetailHeight(int height)
public DynamicReportBuilder setLeftMargin(Integer margin)
public DynamicReportBuilder setLeftMargin(int margin)
public DynamicReportBuilder setRightMargin(Integer margin)
public DynamicReportBuilder setRightMargin(int margin)
public DynamicReportBuilder setTopMargin(Integer margin)
public DynamicReportBuilder setTopMargin(int margin)
public DynamicReportBuilder setBottomMargin(Integer margin)
public DynamicReportBuilder setBottomMargin(int margin)
public DynamicReportBuilder setColumnsPerPage(Integer numColumns)
public DynamicReportBuilder setColumnsPerPage(int numColumns)
public DynamicReportBuilder setColumnsPerPage(int numColumns, int columnSpace)
public DynamicReportBuilder setColumnsPerPage(Integer numColumns, Integer columnSpace)
public DynamicReportBuilder setColumnSpace(Integer columSpace)
public DynamicReportBuilder setColumnSpace(int columSpace)
public DynamicReportBuilder setPrintColumnNames(boolean bool)
bool
- public DynamicReportBuilder setIgnorePagination(boolean bool)
bool
- public DynamicReportBuilder setUseFullPageWidth(boolean useFullwidth)
public DynamicReportBuilder setUseFullPageWidth(Boolean useFullwidth)
public DynamicReportBuilder setTitleStyle(Style titleStyle)
public DynamicReportBuilder setSubtitleStyle(Style subtitleStyle)
public DynamicReportBuilder setPrintBackgroundOnOddRows(boolean printBackgroundOnOddRows)
public DynamicReportBuilder setPrintBackgroundOnOddRows(Boolean printBackgroundOnOddRows)
public DynamicReportBuilder setOddRowBackgroundStyle(Style oddRowBackgroundStyle)
public DynamicReportBuilder setGrandTotalLegend(String title)
public DynamicReportBuilder setGlobalHeaderVariableHeight(Integer height)
public DynamicReportBuilder setGlobalFooterVariableHeight(Integer height)
public DynamicReportBuilder addGlobalHeaderVariable(AbstractColumn col, DJCalculation op)
col
- op
- public DynamicReportBuilder addGlobalHeaderVariable(AbstractColumn col, DJCalculation op, Style style)
public DynamicReportBuilder addGlobalHeaderVariable(AbstractColumn col, DJCalculation op, Style style, DJValueFormatter valueFormatter)
public DynamicReportBuilder addGlobalHeaderVariable(DJGroupVariable variable)
public DynamicReportBuilder addGlobalHeaderVariable(AbstractColumn column, CustomExpression valueExpression)
public DynamicReportBuilder addGlobalHeaderVariable(AbstractColumn column, CustomExpression valueExpression, Style style)
public DynamicReportBuilder addGlobalFooterVariable(AbstractColumn col, DJCalculation op)
col
- op
- public DynamicReportBuilder addGlobalFooterVariable(AbstractColumn col, DJCalculation op, Style style)
public DynamicReportBuilder addGlobalFooterVariable(AbstractColumn col, DJCalculation op, Style style, DJValueFormatter valueFormatter)
public DynamicReportBuilder addGlobalFooterVariable(DJGroupVariable variable)
public DynamicReportBuilder addGlobalFooterVariable(AbstractColumn column, CustomExpression valueExpression)
public DynamicReportBuilder addGlobalFooterVariable(AbstractColumn column, CustomExpression valueExpression, Style style)
public DynamicReportBuilder addGlobalColumnVariable(String position, AbstractColumn col, DJCalculation op)
public DynamicReportBuilder addGlobalColumnVariable(String position, AbstractColumn col, DJCalculation op, Style style)
public DynamicReportBuilder addGlobalColumnVariable(String position, AbstractColumn col, DJCalculation op, Style style, DJValueFormatter valueFormatter)
public DynamicReportBuilder addGlobalColumnVariable(String position, DJGroupVariable variable)
public DynamicReportBuilder addGlobalColumnVariable(String position, AbstractColumn column, CustomExpression valueExpression)
public DynamicReportBuilder addGlobalColumnVariable(String position, AbstractColumn column, CustomExpression valueExpression, Style style)
position
- DJConstants.FOOTER or DJConstants.HEADERcolumn
- column to operate withvalueExpression
- style
- public DynamicReportBuilder addGlobalVariable(String name, AbstractColumn col, DJCalculation op)
name
- col
- op
- public DynamicReportBuilder addGlobalVariable(String name, ColumnProperty prop, DJCalculation op)
name
- prop
- op
- addGlobalVariable(String, AbstractColumn, DJCalculation)
public DynamicReportBuilder addGlobalVariable(String name, String property, String className, DJCalculation op)
name
- property
- className
- op
- addGlobalVariable(String, AbstractColumn, DJCalculation)
public DynamicReportBuilder setTitleHeight(Integer height)
public DynamicReportBuilder setSubtitleHeight(Integer height)
public DynamicReportBuilder setPageSizeAndOrientation(Page page)
page
- public DynamicReportBuilder addImageBanner(String path, Integer width, Integer height, byte align)
public DynamicReportBuilder addImageBanner(String path, Integer width, Integer height, byte align, ImageScaleMode scaleMode)
public DynamicReportBuilder addFooterImageBanner(String path, Integer width, Integer height, byte align, ImageScaleMode scaleMode)
public DynamicReportBuilder addFirstPageImageBanner(String path, Integer width, Integer height, byte align)
public DynamicReportBuilder addFirstPageFooterImageBanner(String path, Integer width, Integer height, byte align)
public DynamicReportBuilder addFirstPageImageBanner(String path, Integer width, Integer height, byte align, ImageScaleMode scaleMode)
public DynamicReportBuilder addField(String name, String className)
name
- className
- public DynamicReportBuilder addField(String name, Class clazz)
public DynamicReportBuilder addField(ColumnProperty columnProperty)
columnProperty
- public List getFields()
public DynamicReportBuilder addChart(DJChart chart)
public DynamicReportBuilder addChart(DJChart djChart)
djChart
- a DJ chartpublic DynamicReportBuilder setTemplateFile(String path)
path
- public DynamicReportBuilder setTemplateFile(String path, boolean importFields, boolean importVariables, boolean importParameters, boolean importDatasets)
path
- public DynamicReportBuilder setMargins(int top, int bottom, int left, int right)
public DynamicReportBuilder setDefaultStyles(Style title, Style subtitle, Style columnHeader, Style columDetail)
public DynamicReportBuilder setReportLocale(Locale locale)
locale
- public DynamicReportBuilder addConcatenatedReport(Subreport subreport)
subreport
- public DynamicReportBuilder addConcatenatedReport(DynamicReport dynamicReport, LayoutManager layoutManager, String dataSourcePath, int dataSourceOrigin, int dataSourceType) throws DJBuilderException
DJBuilderException
public DynamicReportBuilder addConcatenatedReport(DynamicReport dynamicReport, LayoutManager layoutManager, String dataSourcePath, int dataSourceOrigin, int dataSourceType, boolean startOnNewPage) throws DJBuilderException
DJBuilderException
public DynamicReportBuilder addConcatenatedReport(net.sf.jasperreports.engine.JasperReport jasperReport, String dataSourcePath, int dataSourceOrigin, int dataSourceType) throws DJBuilderException
DJBuilderException
public DynamicReportBuilder addConcatenatedReport(net.sf.jasperreports.engine.JasperReport jasperReport, String dataSourcePath, int dataSourceOrigin, int dataSourceType, boolean startOnNewPage) throws DJBuilderException
DJBuilderException
public DynamicReportBuilder addSubreportInGroupFooter(int groupNumber, Subreport subreport)
groupNumber
- subreport
- public DynamicReportBuilder addSubreportInGroupFooter(int groupNumber, DynamicReport dynamicReport, LayoutManager layoutManager, String dataSourcePath, int dataSourceOrigin, int dataSourceType) throws DJBuilderException
DJBuilderException
public DynamicReportBuilder addSubreportInGroupFooter(int groupNumber, DynamicReport dynamicReport, LayoutManager layoutManager, String dataSourcePath, int dataSourceOrigin, int dataSourceType, SubreportParameter[] params) throws DJBuilderException
DJBuilderException
public DynamicReportBuilder addSubreportInGroup(String position, int groupNumber, DynamicReport dynamicReport, LayoutManager layoutManager, String dataSourcePath, int dataSourceOrigin, int dataSourceType, SubreportParameter[] params) throws DJBuilderException
position
- DJConstants.FOOTER
or DJConstants.HEADER
groupNumber
- dynamicReport
- layoutManager
- dataSourcePath
- dataSourceOrigin
- dataSourceType
- params
- DJBuilderException
public DynamicReportBuilder addSubreportInGroupHeader(int groupNumber, DynamicReport dynamicReport, LayoutManager layoutManager, String dataSourcePath, int dataSourceOrigin, int dataSourceType, SubreportParameter[] params) throws DJBuilderException
DJBuilderException
public DynamicReportBuilder addSubreportInGroupFooter(int groupNumber, DynamicReport dynamicReport, LayoutManager layoutManager, String dataSourcePath, int dataSourceOrigin, int dataSourceType, SubreportParameter[] params, boolean startInNewPage) throws DJBuilderException
DJBuilderException
public DynamicReportBuilder addSubreportInGroupHeader(int groupNumber, DynamicReport dynamicReport, LayoutManager layoutManager, String dataSourcePath, int dataSourceOrigin, int dataSourceType, SubreportParameter[] params, boolean startInNewPage) throws DJBuilderException
DJBuilderException
public DynamicReportBuilder addSubreportInGroupFooter(int groupNumber, DynamicReport dynamicReport, LayoutManager layoutManager, String dataSourcePath, int dataSourceOrigin, int dataSourceType, SubreportParameter[] params, boolean startInNewPage, boolean fitParent) throws DJBuilderException
DJBuilderException
public DynamicReportBuilder addSubreportInGroup(String position, int groupNumber, DynamicReport dynamicReport, LayoutManager layoutManager, String dataSourcePath, int dataSourceOrigin, int dataSourceType, SubreportParameter[] params, boolean startInNewPage, boolean fitParent) throws DJBuilderException
position
- position DJConstants.FOOTER
or DJConstants.HEADER
groupNumber
- dynamicReport
- layoutManager
- dataSourcePath
- dataSourceOrigin
- dataSourceType
- params
- startInNewPage
- fitParent
- DJBuilderException
public DynamicReportBuilder addSubreportInGroupHeader(int groupNumber, DynamicReport dynamicReport, LayoutManager layoutManager, String dataSourcePath, int dataSourceOrigin, int dataSourceType, SubreportParameter[] params, boolean startInNewPage, boolean fitParent) throws DJBuilderException
DJBuilderException
public DynamicReportBuilder addSubreportInGroupFooter(int groupNumber, String pathToSubreport, String dataSourcePath, int dataSourceOrigin, int dataSourceType) throws DJBuilderException
DJBuilderException
public DynamicReportBuilder addSubreportInGroupFooter(int groupNumber, String pathToSubreport, String dataSourcePath, int dataSourceOrigin, int dataSourceType, boolean startInNewPage) throws DJBuilderException
DJBuilderException
public DynamicReportBuilder addSubreportInGroupHeader(int groupNumber, Subreport subreport)
public DynamicReportBuilder addSubreportInGroupHeader(int groupNumber, DynamicReport dynamicReport, LayoutManager layoutManager, String dataSourcePath, int dataSourceOrigin, int dataSourceType) throws DJBuilderException
DJBuilderException
public DynamicReportBuilder addSubreportInGroupHeader(int groupNumber, String pathToSubreport, String dataSourcePath, int dataSourceOrigin, int dataSourceType) throws DJBuilderException
DJBuilderException
public DynamicReportBuilder addStyle(Style style) throws DJBuilderException
style
- DJBuilderException
public DynamicReportBuilder addResourceBundle(String resourceBundle)
resourceBundle
- public DynamicReportBuilder setResourceBundle(String resourceBundle)
public DynamicReportBuilder setGrandTotalLegendStyle(Style grandTotalStyle)
public DynamicReportBuilder addHeaderCrosstab(DJCrosstab cross)
cross
- public DynamicReportBuilder addFooterCrosstab(DJCrosstab cross)
cross
- public DynamicReportBuilder setQuery(String text, String language)
text
- language
- use constants from DJConstants
public DynamicReportBuilder addFont(String fontName, Font font)
public DynamicReportBuilder setWhenNoDataType(byte whenNoDataType)
DJConstants.WHEN_NO_DATA_TYPE_NO_PAGES
public DynamicReportBuilder setWhenNoDataNoPages()
setWhenNoDataType(byte)
public DynamicReportBuilder setWhenNoDataBlankPage()
setWhenNoDataType(byte)
public DynamicReportBuilder setWhenNoDataAllSectionNoDetail()
setWhenNoDataType(byte)
public DynamicReportBuilder setWhenNoDataShowNoDataSection()
setWhenNoDataType(byte)
public DynamicReportBuilder setWhenResourceMissing(byte whenResourceMissing)
whenResourceMissing
- public DynamicReportBuilder setWhenResourceMissingLeaveEmptySpace()
public DynamicReportBuilder setWhenResourceMissingThrowException()
public DynamicReportBuilder setWhenResourceMissingShowKey()
public DynamicReportBuilder setWhenResourceMissingReturnNull()
public DynamicReportBuilder setWhenNoData(String text, Style style)
text
- style
- : the style of the textpublic DynamicReportBuilder setWhenNoData(String text, Style style, boolean showTitle, boolean showColumnHeader)
text
- style
- : the style of the textshowTitle
- : if true, the title is shownshowColumnHeader
- : if true, the column headers are shownpublic DynamicReportBuilder addParameter(String name, String className)
public DynamicReportBuilder setAllowDetailSplit(boolean split)
split
- public DynamicReportBuilder setProperty(String name, String value)
name
- value
- public DynamicReportBuilder setShowDetailBand(boolean bool)
bool
- public AbstractColumn getColumn(int idx)
idx
- public DJGroup getGroup(int idx)
idx
- public DynamicReportBuilder setTitle(String title, boolean isExpression)
public DynamicReportBuilder addVariable(DJVariable var)
var
- public DynamicReportBuilder setColspan(int colNumber, int colQuantity, String colspanTitle)
colNumber
- the index of the colcolQuantity
- the number of cols how i will takecolspanTitle
- colspan titleColumnBuilderException
- When the index of the cols is out of bounds.public DynamicReportBuilder setColspan(int colNumber, int colQuantity, String colspanTitle, Style colspanStyle)
public DynamicReportBuilder setLanguage(String language)
language
- DJConstants#REPORT_LANGUAGE_GROOVY
DJConstants#REPORT_LANGUAGE_JAVASCRIPT
,
DynamicReport.language
public DynamicReportBuilder addWatermark(String text)
public DynamicReportBuilder addWatermark(DJWaterMark waterMark)
public DynamicReportBuilder addWatermark(String text, Font font, Color color, int angle)
Copyright © 2006–2015 FDV Solutions. All rights reserved.