JApplet: destroy() : JApplet « javax.swing « Java by API






JApplet: destroy()


import java.awt.Graphics;

import javax.swing.JApplet;

public class MainClass extends JApplet {
  String str = "";

  public void init() {
    str += "init; ";
  }

  public void start() {
    str += "start; ";
  }

  public void stop() {
    str += "stop; ";
  }

  public void destroy() {
    System.out.println("destroy");
  }

  public void paint(Graphics g) {
    g.drawString(str, 10, 25);
  }
}

           
       








Related examples in the same category

1.JApplet: init()
2.JApplet: paint(Graphics g)
3.JApplet: setJMenuBar(JMenuBar menuBar)
4.JApplet: showStatus(String text)
5.JApplet: start()
6.JApplet: stop()