Jump to content
Changes to the Jaspersoft community edition download ×

imageMap JRHtmlExporter

Recommended Posts

By: Edgar Dollin - edollin

imageMap JRHtmlExporter

2003-03-19 11:14

In your webapp examples you have an image which is fully resolved in WebappReport.xml. In the JRHtmlExporter it is looking for an image map which you supply empty. Looking at the code it is not clear what the purpose of the image map is. Could you please explain.


Many thanks







By: Teodor Danciu - teodord

RE: imageMap JRHtmlExporter

2003-03-25 14:21




We supply an empty map to the built-in HTML

exporter so that it can place the images

in this map.

After the report is generated, we have a special

servlet/jsp that can deliver the images based

on their names from this in-memory image map.

Why? without the map, the exporter would have

to put the images somewhere on disk and the web

server would have to deliver them from that location.

In web environment, generating files on disk could

get very tricky especially when dealing with

simultaneous requests.

But if the reports are generated in memory,

then the output of different request can

be separated using the sessions.


Simply put, by default, the HTML exporter

generates an HTML file on disk accompanied by

a directory containing all the images as files.

But if you don't want to generated files on disk

(and in Web you don't want to), then you give it

a map to put the images in and a string buffer to

put the HTML text.

Then you deal with this in-memory content in

your servlets or JSPs like you can see in

the "webapp" sample.


I hope this helps.


Link to comment
Share on other sites

  • Replies 0
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Create New...