public JRRenderable createImage(JRComponentElement componentElement,
BarcodeGenerator barcode, String message, int orientation)
{
try
{
SVGCanvasProvider provider = new SVGCanvasProvider(false, orientation);
barcode.generateBarcode(provider, message);
Document svgDoc = provider.getDOM();
Source source = new DOMSource(svgDoc);
StringWriter outWriter = new StringWriter();
Result output = new StreamResult(outWriter);
Transformer transformer = TransformerFactory.newInstance()