Class PasswordWindow

java.lang.Object
passwordmanagergui.passwords.PasswordWindow

public class PasswordWindow extends Object
Windows for creating, updating and deleting an account
Since:
2024-01-31
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private String
    Group password
    private passwordmanager.encoded.IRawData
    Changed group of passwords in encrypted form
    private String
    Information of the created account
    private JTextField
    Field for entering account information
    private String
    Login of the created account
    private JTextField
    Field for entering account login
    private String
    Password of the created account
    Field for entering account password
    private boolean
    Window closed status
    private final boolean
    Field responsible for whether the window is modal
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    create(JFrame mainWindow, String password, passwordmanager.encoded.IRawData rawData)
    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
    private void
    Method that creates a new account, adds it to a group, and then saves the group
    private void
    editPasswordRecord(String oldRecordLogin, String oldRecordPassword)
    Method that updates information about an existing account and then saves the group
    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
    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
    private void
    Method that waits for the window to close and then returns the result

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • windowIsModal

      private final boolean windowIsModal
      Field responsible for whether the window is modal
      See Also:
    • windowIsClosed

      private boolean windowIsClosed
      Window closed status
    • recordInfo

      private String recordInfo
      Information of the created account
    • recordLogin

      private String recordLogin
      Login of the created account
    • recordPassword

      private String recordPassword
      Password of the created account
    • recordInfoField

      private JTextField recordInfoField
      Field for entering account information
    • recordLoginField

      private JTextField recordLoginField
      Field for entering account login
    • recordPasswordField

      private JPasswordField recordPasswordField
      Field for entering account password
    • rawData

      private passwordmanager.encoded.IRawData rawData
      Changed group of passwords in encrypted form
    • password

      private String password
      Group password
  • Constructor Details

    • PasswordWindow

      public PasswordWindow()
  • Method Details

    • create

      public void create(JFrame mainWindow, String password, passwordmanager.encoded.IRawData rawData)
      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 window
      password - group password
      rawData - 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 login
      recordPassword - account password
      password - group password
      rawData - 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 window
      oldRecordInfo - account information to find it
      oldRecordLogin - account login to find it
      oldRecordPassword - account password to find it
      password - group password
      rawData - password group to which you need to add a new account
    • editPasswordRecord

      private void editPasswordRecord(String oldRecordLogin, String oldRecordPassword)
      Method that updates information about an existing account and then saves the group
      Parameters:
      oldRecordLogin - account login to find it
      oldRecordPassword - account password to find it