Results 1 to 3 of 3

Thread: Controller and OutputStream

  1. #1

    Default Controller and OutputStream

    Hi,

    I want to show after passing in my controller a pdf, png, gif or jpeg file create using itext/jfreegraph in my controller.

    What is the best way ?

    Is it possible to return a stream instead of a view ? Must i use a simple servlet instead but in that case can i use my managers ?

    Thanks,

    Fabien.

  2. #2

    Default

    Check the "countries" sample application. There is a good exemple of using the pdf view.

  3. #3
    Join Date
    Aug 2004
    Location
    San Mateo, CA
    Posts
    1,265

    Default

    If you're doing something unusual for which no view (custom or out-of-the-box) is appropriate, you can return null from your Controller, which tells the Spring MVC framework that you've taken care of writing to the ServletOutputStream yourself.
    Rod Johnson - GM, SpringSource Division, VMware
    http://www.springsource.com
    Spring From the Source

Similar Threads

  1. Replies: 2
    Last Post: Jun 29th, 2005, 03:34 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •