|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
An interface that defines the methods that must be supported by a report output target. JFreeReport currently implements three targets: one for Graphics2D (screen and printer), one for Acrobat PDF files and an other target for PlainText output.
Field Summary | |
static java.lang.String |
AUTHOR
Literal text for the 'author' property name. |
static java.lang.String |
TITLE
Literal text for the 'title' property name. |
Method Summary | |
void |
beginPage(PhysicalPage page)
Signals that a page is being started. |
void |
close()
Closes the target. |
void |
configure(ReportConfiguration config)
Configures the output target. |
OutputTarget |
createDummyWriter()
Creates an output target that mimics a real output target, but produces no output. |
void |
drawDrawable(DrawableContainer drawable)
Draws a drawable relative to the current position. |
void |
drawImage(ImageReference image)
Draws a image relative to the specified coordinates. |
void |
drawShape(java.awt.Shape shape)
Draws a shape relative to the current position. |
void |
drawString(java.lang.String text)
Draws a string at the current cursor position. |
void |
endPage()
Signals that the current page is ended. |
void |
fillShape(java.awt.Shape shape)
Fills the shape relative to the current position. |
FontDefinition |
getFont()
Returns the current font. |
LogicalPage |
getLogicalPage()
Returns the logical page. |
java.awt.geom.Rectangle2D |
getOperationBounds()
Returns the operation bounds. |
java.awt.Paint |
getPaint()
Returns the current paint. |
java.lang.Object |
getProperty(java.lang.String property)
Returns the value of the specified property. |
java.lang.Object |
getProperty(java.lang.String property,
java.lang.Object defaultValue)
Returns the value of the specified property. |
java.awt.Stroke |
getStroke()
Returns the current stroke. |
boolean |
isOpen()
Returns true if the target is open, and false otherwise. |
void |
open()
Opens the target. |
void |
setFont(FontDefinition font)
Sets the font. |
void |
setOperationBounds(java.awt.geom.Rectangle2D bounds)
Defines the bounds for the next set of operations. |
void |
setPaint(java.awt.Paint paint)
Sets the paint. |
void |
setProperty(java.lang.String property,
java.lang.Object value)
Defines a property for this target. |
void |
setStroke(java.awt.Stroke stroke)
Defines the current stroke for the target. |
Methods inherited from interface com.jrefinery.report.targets.base.layout.LayoutSupport |
createTextSizeCalculator, getContentFactory, getHorizontalAlignmentBorder, getVerticalAlignmentBorder |
Field Detail |
public static final java.lang.String TITLE
public static final java.lang.String AUTHOR
Method Detail |
public java.lang.Object getProperty(java.lang.String property, java.lang.Object defaultValue)
defaultValue
is returned.
property
- the property name (or key).defaultValue
- the default value.
java.lang.NullPointerException
- if property
is null.public void setProperty(java.lang.String property, java.lang.Object value)
Properties provide a mechanism for configuring a target. For example, you can add title and author information to a PDF report using the 'title' and 'author' properties.
property
- the property name (key).value
- the property value (use null to remove an existing property).public void open() throws OutputTargetException
OutputTargetException
- if there is some problem opening the target.public boolean isOpen()
public void close()
public void beginPage(PhysicalPage page)
page
- the physical page.public void endPage() throws OutputTargetException
OutputTargetException
- if there is some problem with the target.public java.lang.Object getProperty(java.lang.String property)
null
is returned.
property
- the property name (or key).
java.lang.NullPointerException
- if property
is null.public FontDefinition getFont()
public void setFont(FontDefinition font) throws OutputTargetException
font
- the font.
OutputTargetException
- if there is a problem setting the font.public java.awt.Stroke getStroke()
public void setStroke(java.awt.Stroke stroke) throws OutputTargetException
The stroke is used to draw the outlines of shapes.
stroke
- the stroke.
OutputTargetException
- if there is a problem setting the stroke.public java.awt.Paint getPaint()
public void setPaint(java.awt.Paint paint) throws OutputTargetException
paint
- The paint.
OutputTargetException
- if there is a problem setting the paint.public void setOperationBounds(java.awt.geom.Rectangle2D bounds)
bounds
- the bounds.public java.awt.geom.Rectangle2D getOperationBounds()
public void drawString(java.lang.String text)
text
- the text.public void drawShape(java.awt.Shape shape)
shape
- the shape to draw.public void fillShape(java.awt.Shape shape)
shape
- the shape to draw.public void drawDrawable(DrawableContainer drawable)
drawable
- the drawable to draw.public void drawImage(ImageReference image) throws OutputTargetException
image
- The image to draw (as ImageReference for possible embedding of raw data).
OutputTargetException
- if there is a problem setting the paint.public OutputTarget createDummyWriter()
public void configure(ReportConfiguration config)
config
- the configuration.public LogicalPage getLogicalPage()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |