How To Communicate Between Java Applets Come comunicare tra le applet Java
Communication between Java applets has been an interesting topic from the early days of Java. La comunicazione tra le applet Java è stato un argomento interessante fin dai primi giorni di Java. There are several esoteric ways to communicate like using Javascript as a bridge. Ci sono diversi modi per esoterici come comunicare con il Javascript come un ponte. However we will look into the simplest and most reliable method of intra-applet communication. Tuttavia noi per esaminare la più semplice e più affidabile metodo di intra-applet comunicazione.
Simple solution to applet communication problem Soluzione semplice per applet problema di comunicazione
Use a class with static getters and setters method(s) to pass data around. Utilizzare con una classe statica Getters e metodo contabile (s) di passare nei pressi di dati. Since the applets are loaded in the same JVM, the static methods can be used to share any kind of data between the applets. Dal momento che le applet sono caricati nella stessa JVM, i metodi statici può essere utilizzata per condividere qualsiasi tipo di dati tra le applet.
Another more complex solution is to use the database to communicate data between the applets. Un'altra più complessa soluzione è quella di utilizzare la banca dati per comunicare dati tra le applet. This may be useful if the applets are on different machines or different JVM’s as in two application server / tomcat instances. Questo può essere utile se le applet sono su macchine diverse o diverse JVM come in due server di applicazioni / tomcat istanze.
Filed under Elencato sotto Enterprise Software Enterprise Software , Headline News Headline News , How To Come , J2EE , Java Software Software Java , Javascript , Open Source Software Software open source , Programming Programmazione , Tech Note Nota tech , Web , Web Services Servizi Web | |
| |
RSS 2.0 RSS 2,0 | |
Trackback this Article | questo articolo |
Email this Article Invia questo articolo
You may also like to read Si può anche leggere come |




October 22nd, 2007 at 4:12 pm 22 Ottobre 2007 alle 4:12 pm
hi there, Hi there,
what happens if the JVM applet engine uses different classloaders to load the classes ? cosa succede se la JVM applet motore utilizza diversi classloaders per caricare le classi? there will be 2 different instances of the classes, right ? ci saranno 2 diversi casi di classi, giusto?
BR,
~A ~ Una
October 22nd, 2007 at 11:12 pm 22 Ottobre 2007 alle 11:12 pm
As far as I know both IE & Firefox loads the applets using the same classloader. Per quanto ne so sia di IE e Firefox carica la applet utilizzando le stesse classi.
With different classloaders, yes. Con diversi classloaders, sì.