Standard Applet Methods
The first step in the creation of an applet is to make it a subclass of JApplet, a class in the Swing package javax.swing. An applet is treated as a visual window inside a web page, so JApplet is part of Swing alongside buttons, scrollbars, and other components of a program’s user interface.
The applets you write inherit all the behavior and attributes they need to be run as part of a web page. Before you begin writing any other statements in your applets, they are able to interact with a web browser, load and unload themselves, redraw their windows in response to changes in the browser window, and handle other necessary tasks.
Applications begin running with the first statement inside the main() block. There is no main() ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access