Java application programs have the full access to the local file system and network, Differentiate between Applet and Java Applet, 1.It works at client side so less response time 2.Secured, List the advantages of an applet, Init,start,stop,destroy, Explain the life cycle of an Applet, // A Hello World Applet // Save file as HelloWorld.java import java.applet.Applet; import java.awt.Graphics; // HelloWorld class extends Applet public class HelloWorld extends Applet { // Overriding paint() method public void paint(Graphics g) { g.drawString("Hello World",20, 20); } }  , Create Hello World applet, Applet class extends the java. Panel class and enables you to use the GUI tools in the AWT package. , Which classes can an applet extend?, If not caught thread will die, if an uncaught registered then it will get a callback exception handler is, What happens when an Exception occurs in a thread?, The stop() method is generally used when we death of a thread.desire premature, State the method to stop a thread in Java, 1.Java threading model start() method is used to start newly created thread, while start() internally calls run() method, there is difference calling run() method directly. 2.When you invoke run() as normal method, its called in the same thread, no new thread is started, which is the case when you call start() method., State the difference between start() and run() method of Thread class?.

java multithreading and applet

Classifica

Stile di visualizzazione

Opzioni

Cambia modello

)
Ripristinare il titolo salvato automaticamente: ?