Win a copy of Five Lines of Code this week in the OO, Patterns, UML and Refactoring forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
  • Piet Souris
  • Frits Walraven
  • Carey Brown

few confusions abt applets!

Ranch Hand
Posts: 54
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
im developing a web based chat server using applets. im new to applets so im having some confusion in my mind and want answers to some of my questions.
1) when applet is downloaded on client machine n running in the browser, is this running in client machine's memory space. can i view applet source code?
2) if i want to import some classes(residing on the server) in my applet class how can i make those classes available to my applet after it has been downloaded to the client machine. where should i put those files?
3)in case of private chat every client will chat with every other client. can applet send data to other client machine directly?
4) any suggestion how to implement this chat server?
hope u ppl will reply. thanks
reehan ishaque
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The place to go is (of course):
I'll try to give you a few answers anyway.
1) Yes the downloaded applet code will run on the client machine. The browser (I really only know how IE 5.5 behaves) will cache the class (or jar) files on the client machine. So in order to view the source, you would have to decompile the cached class files.
2) My suggestion. Put the classes you need together in a jar, then make the jar available from the webserver that will host your applet code, i.e. put the jar in the same directory as the class or jar containing your applet.
Then put the <PARAM NAME=ARCHIVE VALUE="comma separated list of jar files"> tag in the html source for your applet launching webpage.
3) No, an applet can only communicate (open sockets) with the server from which it originated.
4) I don't know where to start
Good luck!
So it takes a day for light to pass through this glass? So this was yesterday's tiny ad?
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
    Bookmark Topic Watch Topic
  • New Topic