cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Christian Sengstock" <csengst...@gmail.com>
Subject How to send a "mime-type: image/jpeg" response generated from a BufferedImage
Date Thu, 13 Jul 2006 19:21:57 GMT
Hello list,

in my application i generate dynamically a BufferedImage object and i
want to complete the pipeline with sending the image as a "mime-type:
image/jpeg" response.

At the moment i have a matcher which takes the request and calls a
flowScript function which in turn handles the dynamic creation of the
BufferedImage. Afterwards i save the image to disk and send the URI of
the image-file via the cocoon.sendPage( <filename.jpeg> ) function to
the sitemap, where a reader handles the proper response as a mime-type
image/jpeg.

This is working for me but i thought that there might be a better
approach to do this. Maybe without saving the BufferedImage to disk.

Can anybody give me a hint how to create a "mime-type: image" response
out of a BufferedImage? Maybe it's possible by extending a reader or
by using a serializer?

Thanx a lot,
Chris

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message