Mar 11th, 2008, 02:11 PM
Spring + Jfreechart
I'm trying to represent a chart generated with JFreechart into my jsp but I have a terrible doubt about it.
I return de chart into my mav but I donīt know how to interpretated it into the following jsp. I've been reading something about it and I've seen that I can use cewolf or make directly an image with the chart generated. I don't want to generate an static image.
Somebody can give an example to represent it into my jsp withot creating an static image??
Mar 11th, 2008, 02:53 PM
If you are using Spring Web MVC
you can implement in this way.
1. create an AbstractPDFView as a ModelView : re org.springframework.web.servlet.view.document.Abst ractPDFView;
2. build your document inside the method of buildPDFDocument. (iText PDF document).
but you can change the model or content by adding your document ( jfreeChart image) and provide your own logic and display.
Hope this help!
Mar 11th, 2008, 03:06 PM
Well, maybe I haven't explained at all.
I have generate my chart into my controller but, now, I don't know how to return it into the mav and how to interpretaded it into my JSP.
It could be more than one user into the web so, I think, generate a jpg for each people if can access currently to the same funcionality, it's not a good option.
Do you have an example about how I can do it???