What is the difference between Java Applications and Java Applets?

In this post we will differentiate the differences between a java application and java applets. They are as follows:

Application-Java Application-Applet
Application needs a main() method to start execution. Applet does not need main() method instead it requires init() method for start up.
Application can take inputs from command line and GUI. Applet parameters are embedded into HTML browser document. Can accept inputs from these or GUI
Applications can be loaded from file system or any class library(custom) Codes are transported via HTTP and fits into the browser's predefined area.
It can work on minimum memory Applet codes need to calculate the code memory plus the browser's memory
Application's User graphics mode is optional hence they can sustain without any graphics viz GUI Applet depends on GUI hence it graphical.
Application can work on file I/O and Sockets Applet does not support file I/O and sockets(other than host platform)
Application need not be subclass of any particular class.(By default the classes are sub class of Object class) Applet must be a subclass of java.Applet class.
Application can have menus Applet can not have menus
What is the difference between Java Applications and Java Applets? What is the difference between Java Applications and Java Applets? Reviewed by Animesh Chatterjee on October 29, 2018 Rating: 5

No comments:

Powered by Blogger.