import java.applet.*;
import java.awt.*;
public class life extends Applet
{
String str="";
// Born State
public void init()
{
str+="Executing Born / init state ";
}
// Start State
public void start()
{
str+="Executing Start state ";
}
// Stop / Idle State
public void stop()
{
str+="Executing Stop state ";
}
public void paint(Graphics g)
{
g.drawString(str,25,100);
}
// Dead / Destroy State
public void destroy()
{
System.out.println("Destroy / Dead is calling...");
System.out.println("Applet is deleted from memory...");
}
}
/*<applet code="life.class" height="150" width="150" align="MIDDLE">
</applet>*/
No comments:
Post a Comment