org.jfree.report.content
Interface Content

All Known Subinterfaces:
MultipartContent
All Known Implementing Classes:
ImageContent, EmptyContent, ShapeContent, TextLine, DrawableContent, AnchorContent, RawContent

public interface Content

An interface for report content.

Author:
Thomas Morgner.

Method Summary
 StrictBounds getBounds()
          Returns the bounds for the content.
 Content getContentForBounds(StrictBounds bounds)
          Returns the content for the given bounds.
 ContentType getContentType()
          Returns the content type (the types include TEXT, IMAGE, SHAPE and CONTAINER).
 StrictBounds getMinimumContentSize()
          Returns the minimum content size.
 void translate(long x, long y)
          Hack-Attack: Used for alignment of the content.
 

Method Detail

getContentType

public ContentType getContentType()
Returns the content type (the types include TEXT, IMAGE, SHAPE and CONTAINER).
Returns:
the content type.

getBounds

public StrictBounds getBounds()
Returns the bounds for the content. ContentBounds are always relative to the element bounds.
Returns:
the bounds.

getMinimumContentSize

public StrictBounds getMinimumContentSize()
Returns the minimum content size.
Returns:
the minimum size.

getContentForBounds

public Content getContentForBounds(StrictBounds bounds)
Returns the content for the given bounds. The extracted content is the content that would be displayed in the specific bounds if the content would be printed with clipping enabled at the given boundary.

This method returns null if there is no content in these bounds.

Parameters:
bounds - the bounds.
Returns:
the content (possibly null).

translate

public void translate(long x,
                      long y)
Hack-Attack: Used for alignment of the content. This changes the bounds of the content and all child contents.
Parameters:
x - the x translation.
y - the y translation.