org.jfree.layouting.input

Class EmptyImageData

Implemented Interfaces:
ImageData, Serializable

public class EmptyImageData
extends java.lang.Object
implements ImageData

This is a placeholder for non-resolveable image values.
Author:
Thomas Morgner

Constructor Summary

EmptyImageData()

Method Summary

void
draw(Graphics2D g2, Rectangle2D area)
Draws the object.
long
getHeight()
Dimension
getPreferredSize()
Returns the preferred size of the drawable.
Resource
getSource()
long
getWidth()
boolean
isPreserveAspectRatio()
Returns true, if this drawable will preserve an aspect ratio during the drawing.

Constructor Details

EmptyImageData

public EmptyImageData()

Method Details

draw

public void draw(Graphics2D g2,
                 Rectangle2D area)
Draws the object.
Specified by:
draw in interface ImageData
Parameters:
g2 - the graphics device.
area - the area inside which the object should be drawn.

getHeight

public long getHeight()
Specified by:
getHeight in interface ImageData

getPreferredSize

public Dimension getPreferredSize()
Returns the preferred size of the drawable. If the drawable is aspect ratio aware, these bounds should be used to compute the preferred aspect ratio for this drawable.
Returns:
the preferred size.

getSource

public Resource getSource()
Specified by:
getSource in interface ImageData

getWidth

public long getWidth()
Specified by:
getWidth in interface ImageData

isPreserveAspectRatio

public boolean isPreserveAspectRatio()
Returns true, if this drawable will preserve an aspect ratio during the drawing.
Returns:
true, if an aspect ratio is preserved, false otherwise.