Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    TileGrid Operation or alternative

    I am currently using a tilegrid to display a graph that I generate on the server.
    I have implemented a viewFile DMI method and can successfully display
    the image.

    Is there a way to pass criteria arguments from the original fetch operation
    to the viewFile DMI call. From what I see, the sequence of events is

    1. invoke fetch with lots of criteria for generating the graph
    2. executeFetch() DMI is invoked on the server
    3. I return a dummy filename for now in image_filename
    4. viewFile() DMI is invoked and I see the image_filename I returned from
    the executeFetch().

    I can take the original criteria in the executeFetch and do a toString()
    and set to image_file. However, in the viewFile() DMI method, the
    image_filename argument shows up as a String that I have to parse.

    Is there a way to pass the original criteria to the viewfile operation or to
    parse the string back into a nice List<Map> using a standard method?

    A side question is there a way to display "dynamic images". I.e. something
    like and Img() where you can pass in binary data retrieved from the server rather than having to do a filename?

    Thanks

    #2
    Basically, to do this, the simplest thing is to write your own servlet and receive the criteria in a format of your own choosing (eg as URL parameters). You can still use the DataSource layer to do the fetch of binary information from SQL or wherever you have it stored, grab the InputStream from inside the Records returned to you in the DSResponse, and copy the data into the ServletResponse outputStream.

    Comment

    Working...
    X