Class JXLoginPane.NullPasswordStore

  • Enclosing class:
    JXLoginPane

    private static final class JXLoginPane.NullPasswordStore
    extends PasswordStore
    Simple PasswordStore that does not remember passwords
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      private NullPasswordStore()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean equals​(java.lang.Object obj)  
      char[] get​(java.lang.String username, java.lang.String server)
      Fetches the password for a given server and username.
      int hashCode()  
      void removeUserPassword​(java.lang.String username)
      This should attempt to remove the given username from the password store, as well as any associated password.
      boolean set​(java.lang.String username, java.lang.String server, char[] password)
      Saves a password for future use.
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • NullPasswordStore

        private NullPasswordStore()
    • Method Detail

      • set

        public boolean set​(java.lang.String username,
                           java.lang.String server,
                           char[] password)
        Description copied from class: PasswordStore
        Saves a password for future use.
        Specified by:
        set in class PasswordStore
        Parameters:
        username - username used to authenticate.
        server - server used for authentication
        password - password to save. Password can't be null. Use empty array for empty password.
      • get

        public char[] get​(java.lang.String username,
                          java.lang.String server)
        Description copied from class: PasswordStore
        Fetches the password for a given server and username.
        Specified by:
        get in class PasswordStore
        Parameters:
        username - username
        server - server
        Returns:
        null if not found, a character array representing the password otherwise. Returned array can be empty if the password is empty.
      • removeUserPassword

        public void removeUserPassword​(java.lang.String username)
        Description copied from class: PasswordStore
        This should attempt to remove the given username from the password store, as well as any associated password.
        Specified by:
        removeUserPassword in class PasswordStore
        Parameters:
        username - The username to remove
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object