Swing also implements a JPasswordField which acts much like JTextField, except that the output is hidden from the user.
This is used for entry of confidential input, such as (wait for it!!) passwords.
It has similar constructors and methods to JTextField (see exercises)
However, the JPasswordField class prevents unmasked output from appearing in the field. The character that is echoed to the field is defaulted to an asterisk (*), but it can be changed by the methods:
public char getEchoChar() public void setEchoChar(char c) public boolean echoCharIsSet()