The key elements in a form are instances of the JLabel
class,
the JTextField
class, and the JButton
class. All are
components, so you can connect instances of each to an applet's content
pane.
In practice, however, you are unlikely to connect labels, text fields, or
buttons directly to an applet. Instead, you connect them to an
instance of a subclass of the JPanel
class,
which you connect to an applet's content pane. Thus, you implement a form
by creating a subclass of the JPanel
class.