Class HtmlUnitUsernamePasswordCredentials

java.lang.Object
org.htmlunit.httpclient.HtmlUnitUsernamePasswordCredentials
All Implemented Interfaces:
Serializable, org.apache.http.auth.Credentials

public class HtmlUnitUsernamePasswordCredentials extends Object implements org.apache.http.auth.Credentials, Serializable
Wrapper for UsernamePasswordCredentials to avoid direct references spread around.
See Also:
  • Field Details

    • httpClientUsernamePasswordCredentials_

      private final org.apache.http.auth.UsernamePasswordCredentials httpClientUsernamePasswordCredentials_
  • Constructor Details

    • HtmlUnitUsernamePasswordCredentials

      @Deprecated public HtmlUnitUsernamePasswordCredentials(String userName, String password)
      Deprecated.
      as of version 3.4.0; use HtmlUnitUsernamePasswordCredentials(String, char[]) instead
      The constructor with the username and password arguments.
      Parameters:
      userName - the user name
      password - the password
    • HtmlUnitUsernamePasswordCredentials

      public HtmlUnitUsernamePasswordCredentials(String userName, char[] password)
      The constructor with the username and password arguments.
      Parameters:
      userName - the user name
      password - the password
  • Method Details

    • getPassword

      public String getPassword()
      Specified by:
      getPassword in interface org.apache.http.auth.Credentials
    • getUserPrincipal

      public Principal getUserPrincipal()
      Specified by:
      getUserPrincipal in interface org.apache.http.auth.Credentials
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object