Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

help me!!!!!!!!!!  RSS feed

 
Geoffrey Ren
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I used applet as client. I transfer some parameters to servlet by HTTP. Servlet search some data from DB(List). how do I get the List data. (I want to get the List object).
 
Michael Morris
Ranch Hand
Posts: 3451
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Geoffrey,

I used applet as client. I transfer some parameters to servlet by HTTP. Servlet search some data from DB(List). how do I get the List data. (I want to get the List object).

If you want to get an Object back, why are you using a Servlet? RMI would probably be a much simpler way to get an object back. I suppose, if you must use a Servlet, that you could set the servlet response MIME type to application/octet-stream, wrap the output stream in an ObjectOutputStream and write the List to the stream. Something like this:

Hope this helps,
Michael Morris
 
Geoffrey Ren
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks!!!
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!