1/12
Looks like no tags are added yet.
Name | Mastery | Learn | Test | Matching | Spaced | Call with Kai |
|---|
No analytics yet
Send a link to your students to track their progress
JPasswordField
The object of a ______ class is a text component specialized for password entry. It allows the editing of a single line of text.
public class JPasswordField extends JTextFieldJPasswordField class declaration
JPasswordField()
JPasswordField(int columns)
JPasswordField(String text)
JPasswordField(String text, int columns)
Commonly used Constructors in JPasswordField:
JPasswordField()
Constructs a new JPasswordField, with a default document, null starting text string, and 0 column width.
JPasswordField(int columns)
Constructs a new empty JPasswordField with the specified number of columns.
JPasswordField(String text)
Constructs a new JPasswordField initialized with the specified text.
JPasswordField(String text, int columns)
Construct a new JPasswordField initialized with the specified text and columns.
String getText()
It is used to return the text of the button.
void setEnabled(boolean b)
It is used to enable or disable the button.
void setIcon(Icon b)
It is used to set the specified Icon on the button.
Icon getIcon()
It is used to get the Icon of the button.
void setMnemonic(int a)
It is used to set the mnemonic on the button.
void addActionListener(ActionListener a)
It is used to add the action listener to this object.