net.sf.jasperreports.engine
Interface JRReport

All Superinterfaces:
JRDefaultFontProvider
All Known Implementing Classes:
JRBaseReport

public interface JRReport
extends JRDefaultFontProvider

An abstract representation of a Jasper report. This interface is inherited by all report implementations (designs, compiled reports, filled reports). It only contains constants and getters and setters for the most common report properties and elements.

Version:
$Id: JRReport.java,v 1.17 2005/08/11 09:23:06 teodord Exp $
Author:
Teodor Danciu (teodord@users.sourceforge.net)

Field Summary
static java.lang.String LANGUAGE_JAVA
          A constant used to specify that the language used by expressions is Java.
static byte ORIENTATION_LANDSCAPE
          Specifies a landscape orientation.
static byte ORIENTATION_PORTRAIT
          Specifies a portrait orientation.
static byte PRINT_ORDER_HORIZONTAL
          Specifies that columns in a report should be filled horizontalyy (columns are filled proportionally).
static byte PRINT_ORDER_VERTICAL
          Specifies that columns in a report should be filled vertically (fill an entire column and then go to the next one).
static byte WHEN_NO_DATA_TYPE_ALL_SECTIONS_NO_DETAIL
          Specifies that in case of empty datasources, all sections except detail will displayed.
static byte WHEN_NO_DATA_TYPE_BLANK_PAGE
          Specifies that in case of empty datasources, there will be a report with just one blank page.
static byte WHEN_NO_DATA_TYPE_NO_PAGES
          Specifies that in case of empty datasources, there will be an empty report.
static byte WHEN_RESOURCE_MISSING_TYPE_EMPTY
          Return empty string when a resource is missing.
static byte WHEN_RESOURCE_MISSING_TYPE_ERROR
          Throw an exception when a resource is missing.
static byte WHEN_RESOURCE_MISSING_TYPE_KEY
          Return the key when a resource is missing.
static byte WHEN_RESOURCE_MISSING_TYPE_NULL
          Return NULL when a resource is missing.
 
Method Summary
 JRBand getBackground()
           
 int getBottomMargin()
           
 int getColumnCount()
          Gets the number of columns on each page
 JRBand getColumnFooter()
           
 JRBand getColumnHeader()
           
 int getColumnSpacing()
          Specifies the space between columns on the same page.
 int getColumnWidth()
           
 JRBand getDetail()
           
 JRField[] getFields()
           
 JRReportFont[] getFonts()
          Gets an array of report fonts.
 JRGroup[] getGroups()
           
 java.lang.String[] getImports()
          Gets an array of imports (needed if report expression require additional classes in order to compile).
 java.lang.String getLanguage()
          Gets the report language.
 JRBand getLastPageFooter()
           
 int getLeftMargin()
           
 java.lang.String getName()
          Gets the report name.
 byte getOrientation()
           
 JRBand getPageFooter()
           
 JRBand getPageHeader()
           
 int getPageHeight()
           
 int getPageWidth()
           
 JRParameter[] getParameters()
           
 byte getPrintOrder()
          Specifies whether columns will be filled horizontally or vertically.
 java.lang.String getProperty(java.lang.String name)
          Gets a property value
 java.lang.String[] getPropertyNames()
          Gets an array of report properties names.
 JRQuery getQuery()
           
 java.lang.String getResourceBundle()
          Gets the base name of the report associated resource bundle.
 int getRightMargin()
           
 java.lang.String getScriptletClass()
           
 JRBand getSummary()
           
 JRBand getTitle()
           
 int getTopMargin()
           
 JRVariable[] getVariables()
           
 byte getWhenNoDataType()
          Specifies the report behaviour in case of empty datasources.
 byte getWhenResourceMissingType()
          Returns the resource missing handling type.
 boolean isFloatColumnFooter()
          Specifie if the column footer section will be printed at the bottom of the column or if it will immediately follow the last detail or group footer printed on the current column.
 boolean isSummaryNewPage()
          Specifies if the summary section will be printed on a separate last page.
 boolean isTitleNewPage()
          Specifies if the title section will be printed on a separate initial page.
 void removeProperty(java.lang.String name)
           
 void setProperty(java.lang.String name, java.lang.String value)
           
 void setWhenNoDataType(byte whenNoDataType)
          Sets the report behaviour in case of empty datasources.
 void setWhenResourceMissingType(byte whenResourceMissingType)
          Sets the resource missing handling type.
 
Methods inherited from interface net.sf.jasperreports.engine.JRDefaultFontProvider
getDefaultFont
 

Field Detail

LANGUAGE_JAVA

public static final java.lang.String LANGUAGE_JAVA
A constant used to specify that the language used by expressions is Java.

See Also:
Constant Field Values

PRINT_ORDER_VERTICAL

public static final byte PRINT_ORDER_VERTICAL
Specifies that columns in a report should be filled vertically (fill an entire column and then go to the next one).

See Also:
Constant Field Values

PRINT_ORDER_HORIZONTAL

public static final byte PRINT_ORDER_HORIZONTAL
Specifies that columns in a report should be filled horizontalyy (columns are filled proportionally).

See Also:
Constant Field Values

ORIENTATION_PORTRAIT

public static final byte ORIENTATION_PORTRAIT
Specifies a portrait orientation. This is used mostly to inform printers of page layouts.

See Also:
Constant Field Values

ORIENTATION_LANDSCAPE

public static final byte ORIENTATION_LANDSCAPE
Specifies a landscape orientation. This is used mostly to inform printers of page layouts.

See Also:
Constant Field Values

WHEN_NO_DATA_TYPE_NO_PAGES

public static final byte WHEN_NO_DATA_TYPE_NO_PAGES
Specifies that in case of empty datasources, there will be an empty report.

See Also:
Constant Field Values

WHEN_NO_DATA_TYPE_BLANK_PAGE

public static final byte WHEN_NO_DATA_TYPE_BLANK_PAGE
Specifies that in case of empty datasources, there will be a report with just one blank page.

See Also:
Constant Field Values

WHEN_NO_DATA_TYPE_ALL_SECTIONS_NO_DETAIL

public static final byte WHEN_NO_DATA_TYPE_ALL_SECTIONS_NO_DETAIL
Specifies that in case of empty datasources, all sections except detail will displayed.

See Also:
Constant Field Values

WHEN_RESOURCE_MISSING_TYPE_NULL

public static final byte WHEN_RESOURCE_MISSING_TYPE_NULL
Return NULL when a resource is missing.

See Also:
Constant Field Values

WHEN_RESOURCE_MISSING_TYPE_EMPTY

public static final byte WHEN_RESOURCE_MISSING_TYPE_EMPTY
Return empty string when a resource is missing.

See Also:
Constant Field Values

WHEN_RESOURCE_MISSING_TYPE_KEY

public static final byte WHEN_RESOURCE_MISSING_TYPE_KEY
Return the key when a resource is missing.

See Also:
Constant Field Values

WHEN_RESOURCE_MISSING_TYPE_ERROR

public static final byte WHEN_RESOURCE_MISSING_TYPE_ERROR
Throw an exception when a resource is missing.

See Also:
Constant Field Values
Method Detail

getName

public java.lang.String getName()
Gets the report name.


getLanguage

public java.lang.String getLanguage()
Gets the report language. Should be Java or Groovy.


getColumnCount

public int getColumnCount()
Gets the number of columns on each page


getPrintOrder

public byte getPrintOrder()
Specifies whether columns will be filled horizontally or vertically.

See Also:
PRINT_ORDER_VERTICAL,, PRINT_ORDER_HORIZONTAL

getPageWidth

public int getPageWidth()

getPageHeight

public int getPageHeight()

getOrientation

public byte getOrientation()

getWhenNoDataType

public byte getWhenNoDataType()
Specifies the report behaviour in case of empty datasources.


setWhenNoDataType

public void setWhenNoDataType(byte whenNoDataType)
Sets the report behaviour in case of empty datasources.


getColumnWidth

public int getColumnWidth()

getColumnSpacing

public int getColumnSpacing()
Specifies the space between columns on the same page.


getLeftMargin

public int getLeftMargin()

getRightMargin

public int getRightMargin()

getTopMargin

public int getTopMargin()

getBottomMargin

public int getBottomMargin()

isTitleNewPage

public boolean isTitleNewPage()
Specifies if the title section will be printed on a separate initial page.


isSummaryNewPage

public boolean isSummaryNewPage()
Specifies if the summary section will be printed on a separate last page.


isFloatColumnFooter

public boolean isFloatColumnFooter()
Specifie if the column footer section will be printed at the bottom of the column or if it will immediately follow the last detail or group footer printed on the current column.


getScriptletClass

public java.lang.String getScriptletClass()

getResourceBundle

public java.lang.String getResourceBundle()
Gets the base name of the report associated resource bundle.


getPropertyNames

public java.lang.String[] getPropertyNames()
Gets an array of report properties names.


getProperty

public java.lang.String getProperty(java.lang.String name)
Gets a property value

Parameters:
name - the property name

setProperty

public void setProperty(java.lang.String name,
                        java.lang.String value)

removeProperty

public void removeProperty(java.lang.String name)

getImports

public java.lang.String[] getImports()
Gets an array of imports (needed if report expression require additional classes in order to compile).


getFonts

public JRReportFont[] getFonts()
Gets an array of report fonts.


getParameters

public JRParameter[] getParameters()

getQuery

public JRQuery getQuery()

getFields

public JRField[] getFields()

getVariables

public JRVariable[] getVariables()

getGroups

public JRGroup[] getGroups()

getBackground

public JRBand getBackground()

getTitle

public JRBand getTitle()

getPageHeader

public JRBand getPageHeader()

getColumnHeader

public JRBand getColumnHeader()

getDetail

public JRBand getDetail()

getColumnFooter

public JRBand getColumnFooter()

getPageFooter

public JRBand getPageFooter()

getLastPageFooter

public JRBand getLastPageFooter()

getSummary

public JRBand getSummary()

getWhenResourceMissingType

public byte getWhenResourceMissingType()
Returns the resource missing handling type.


setWhenResourceMissingType

public void setWhenResourceMissingType(byte whenResourceMissingType)
Sets the resource missing handling type.

Parameters:
whenResourceMissingType - the resource missing handling type


© 2001-2005 JasperSoft Corporation www.jaspersoft.com