File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JSP and the fly likes passing object from JSTL into applet Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSP
Bookmark "passing object from JSTL into applet" Watch "passing object from JSTL into applet" New topic
Author

passing object from JSTL into applet

Benjamin Weaver
Ranch Hand

Joined: Apr 08, 2003
Posts: 161
I have JSTL code that looks like this:



I would like to pass each 'text' object into an applet. The text object is not a string.

I know I could have the applet call the server for a serialized instance of a text object, but I would rather pass the object into the applet straight from JSTL, such that I could get a handle to the instance within the applet with some kind of getParameter() call or similar call to AppletContext
Benjamin Weaver
Ranch Hand

Joined: Apr 08, 2003
Posts: 161
I should have mentioned that the JSTL snippet is enclosed within

tags.

I can feed string params into the applet just fine from JSTL using




But I am looking for a way to pass in non-string objects.
>
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41861
    
  63
Since this is HTML we're talking about, only text strings are possible. If it's for some reason not possible to pass a string representation of the object, then a serialized object may work (as long as it's properly ASCII-ized by using base-64 or something like that).

Note that serialization generally requires that both JVMs are of the same version (e.g., Java 5 or Java 6).


Ping & DNS - my free Android networking tools app
Benjamin Weaver
Ranch Hand

Joined: Apr 08, 2003
Posts: 161
Thanks, Ulf. This is good to know.
 
 
subject: passing object from JSTL into applet