AWT Component Class
Introduction The Component class is the abstract base class for the non-menu user-interface controls of AWT. A component represents an object with graphical representation. Class declaration Following is the declaration for java.awt.Component class: public…