Package net.sf.jasperreports.renderers
Class WrappingSvgDataToGraphics2DRenderer
- java.lang.Object
-
- net.sf.jasperreports.renderers.AbstractRenderer
-
- net.sf.jasperreports.renderers.AbstractRenderToImageAwareRenderer
-
- net.sf.jasperreports.renderers.AbstractSvgDataToGraphics2DRenderer
-
- net.sf.jasperreports.renderers.WrappingSvgDataToGraphics2DRenderer
-
- All Implemented Interfaces:
Serializable
,AreaHyperlinksRenderable
,DataRenderable
,DimensionRenderable
,Graphics2DRenderable
,Renderable
,RenderToImageAwareRenderable
public class WrappingSvgDataToGraphics2DRenderer extends AbstractSvgDataToGraphics2DRenderer
SVG renderer implementation based on Batik.- Author:
- Teodor Danciu (teodord@users.sourceforge.net)
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from interface net.sf.jasperreports.renderers.Renderable
PROPERTY_IMAGE_DPI
-
-
Constructor Summary
Constructors Constructor Description WrappingSvgDataToGraphics2DRenderer(DataRenderable dataRenderer)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Graphics2D
createGraphics(BufferedImage bi)
byte[]
getData(JasperReportsContext jasperReportsContext)
List<JRPrintImageAreaHyperlink>
getImageAreaHyperlinks(Rectangle2D renderingArea)
Returns the list ofimage map areas
.int
getImageDataDPI(JasperReportsContext jasperReportsContext)
protected org.w3c.dom.svg.SVGDocument
getSvgDocument(JasperReportsContext jasperReportsContext, org.apache.batik.dom.svg.SVGDocumentFactory documentFactory)
boolean
hasImageAreaHyperlinks()
Indicates whether the renderer actually includes any image map areas.-
Methods inherited from class net.sf.jasperreports.renderers.AbstractSvgDataToGraphics2DRenderer
getDimension, getRootNode, render
-
Methods inherited from class net.sf.jasperreports.renderers.AbstractRenderer
getId
-
-
-
-
Constructor Detail
-
WrappingSvgDataToGraphics2DRenderer
public WrappingSvgDataToGraphics2DRenderer(DataRenderable dataRenderer)
-
-
Method Detail
-
getSvgDocument
protected org.w3c.dom.svg.SVGDocument getSvgDocument(JasperReportsContext jasperReportsContext, org.apache.batik.dom.svg.SVGDocumentFactory documentFactory) throws JRException
- Specified by:
getSvgDocument
in classAbstractSvgDataToGraphics2DRenderer
- Throws:
JRException
-
getImageAreaHyperlinks
public List<JRPrintImageAreaHyperlink> getImageAreaHyperlinks(Rectangle2D renderingArea) throws JRException
Description copied from interface:AreaHyperlinksRenderable
Returns the list ofimage map areas
.- Specified by:
getImageAreaHyperlinks
in interfaceAreaHyperlinksRenderable
- Overrides:
getImageAreaHyperlinks
in classAbstractSvgDataToGraphics2DRenderer
- Parameters:
renderingArea
- the area on which the image would be rendered- Returns:
- a list of
JRPrintImageAreaHyperlink
instances. - Throws:
JRException
-
hasImageAreaHyperlinks
public boolean hasImageAreaHyperlinks()
Description copied from interface:AreaHyperlinksRenderable
Indicates whether the renderer actually includes any image map areas.- Specified by:
hasImageAreaHyperlinks
in interfaceAreaHyperlinksRenderable
- Overrides:
hasImageAreaHyperlinks
in classAbstractSvgDataToGraphics2DRenderer
- Returns:
- whether the renderer actually includes any image map areas
-
getData
public byte[] getData(JasperReportsContext jasperReportsContext) throws JRException
- Throws:
JRException
-
getImageDataDPI
public int getImageDataDPI(JasperReportsContext jasperReportsContext)
- Specified by:
getImageDataDPI
in interfaceRenderToImageAwareRenderable
- Overrides:
getImageDataDPI
in classAbstractRenderToImageAwareRenderer
-
createGraphics
public Graphics2D createGraphics(BufferedImage bi)
- Specified by:
createGraphics
in interfaceRenderToImageAwareRenderable
- Overrides:
createGraphics
in classAbstractSvgDataToGraphics2DRenderer
-
-