Package passwordmanagergui.passwords
Class PasswordWindow
java.lang.Object
passwordmanagergui.passwords.PasswordWindow
Windows for creating, updating and deleting an account
- Since:
- 2024-01-31
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate StringGroup passwordprivate passwordmanager.encoded.IRawDataChanged group of passwords in encrypted formprivate StringInformation of the created accountprivate JTextFieldField for entering account informationprivate StringLogin of the created accountprivate JTextFieldField for entering account loginprivate StringPassword of the created accountprivate JPasswordFieldField for entering account passwordprivate booleanWindow closed statusprivate final booleanField responsible for whether the window is modal -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidA method that creates a window for entering information about a new account with the ability to confirm or cancel the creation of a new accountprivate voidMethod that creates a new account, adds it to a group, and then saves the groupprivate voideditPasswordRecord(String oldRecordLogin, String oldRecordPassword) Method that updates information about an existing account and then saves the groupvoidremovePasswordRecord(String recordLogin, String recordPassword, String password, passwordmanager.encoded.IRawData rawData) A method that removes an account from a group and saves the groupvoidupdate(JFrame mainWindow, String oldRecordInfo, String oldRecordLogin, String oldRecordPassword, String password, passwordmanager.encoded.IRawData rawData) A method that creates a window for entering new information about an existing account with the ability to confirm or cancel the account changeprivate voidMethod that waits for the window to close and then returns the result
-
Field Details
-
windowIsModal
private final boolean windowIsModalField responsible for whether the window is modal- See Also:
-
windowIsClosed
private boolean windowIsClosedWindow closed status -
recordInfo
Information of the created account -
recordLogin
Login of the created account -
recordPassword
Password of the created account -
recordInfoField
Field for entering account information -
recordLoginField
Field for entering account login -
recordPasswordField
Field for entering account password -
rawData
private passwordmanager.encoded.IRawData rawDataChanged group of passwords in encrypted form -
password
Group password
-
-
Constructor Details
-
PasswordWindow
public PasswordWindow()
-
-
Method Details
-
create
A method that creates a window for entering information about a new account with the ability to confirm or cancel the creation of a new account- Parameters:
mainWindow- parent windowpassword- group passwordrawData- password group to which you need to add a new account
-
createPasswordRecord
private void createPasswordRecord()Method that creates a new account, adds it to a group, and then saves the group -
waitWindowClose
private void waitWindowClose()Method that waits for the window to close and then returns the result -
removePasswordRecord
public void removePasswordRecord(String recordLogin, String recordPassword, String password, passwordmanager.encoded.IRawData rawData) A method that removes an account from a group and saves the group- Parameters:
recordLogin- account loginrecordPassword- account passwordpassword- group passwordrawData- encoded group
-
update
public void update(JFrame mainWindow, String oldRecordInfo, String oldRecordLogin, String oldRecordPassword, String password, passwordmanager.encoded.IRawData rawData) A method that creates a window for entering new information about an existing account with the ability to confirm or cancel the account change- Parameters:
mainWindow- parent windowoldRecordInfo- account information to find itoldRecordLogin- account login to find itoldRecordPassword- account password to find itpassword- group passwordrawData- password group to which you need to add a new account
-
editPasswordRecord
Method that updates information about an existing account and then saves the group- Parameters:
oldRecordLogin- account login to find itoldRecordPassword- account password to find it
-