Win a copy of Learn Spring Security (video course) this week in the Spring forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Applet to Servlet Communication

 
Mohit Agarwal
Ranch Hand
Posts: 88
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi to all ,

I had a Applet which needs to read some data from the database.
The data is read from the database via a Servlet .The requisite data
is there in the Value Objects wrapped inside an ArrayList .
The servlet makes a ObjectOutputStream object passing
response.getOutputStream() as the argument & writes the ArrayList obj
in the output stream .

In the applet , i make a URL Connection obj named servletconnection. which points to that servlet .
Upto this point everything goes fine & the connection is established .
Now i make a ObjectInputStream obj & passes the arg as servletconnection.getInputStream().
When i prints the available size it shows as 0.
Am i not pointing to the correct stream .

Pls. help me out .

Bye n Tanks in Advance ,


Reagrds,
Mohit.
 
Annie Smith
Ranch Hand
Posts: 172
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There are some good examples here that might help!
 
Manuel Moons
Ranch Hand
Posts: 229
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For applet-servlet communication the jakarta httpclient api is always interesting.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic