Class ExchangeFilterFunctions.Credentials
java.lang.Object
org.springframework.web.reactive.function.client.ExchangeFilterFunctions.Credentials
- Enclosing class:
- ExchangeFilterFunctions
Deprecated.
Stores username and password for HTTP basic authentication.
-
Constructor Summary
ConstructorsConstructorDescriptionCredentials(String username, String password) Deprecated.Create a newCredentialsinstance with the given username and password. -
Method Summary
Modifier and TypeMethodDescriptionbasicAuthenticationCredentials(String username, String password) Deprecated.Return a Consumer that stores the given username and password as a request attribute of typeCredentialsthat is in turn used byExchangeFilterFunctions.basicAuthentication().booleanDeprecated.inthashCode()Deprecated.
-
Constructor Details
-
Credentials
Deprecated.Create a newCredentialsinstance with the given username and password.- Parameters:
username- the usernamepassword- the password
-
-
Method Details
-
basicAuthenticationCredentials
public static Consumer<Map<String,Object>> basicAuthenticationCredentials(String username, String password) Deprecated.Return a Consumer that stores the given username and password as a request attribute of typeCredentialsthat is in turn used byExchangeFilterFunctions.basicAuthentication().- Parameters:
username- the usernamepassword- the password- Returns:
- a consumer that can be passed into ClientRequest.Builder.attributes(java.util.function.Consumer)
- See Also:
-
ClientRequest.Builder.attributes(java.util.function.Consumer)ExchangeFilterFunctions.BASIC_AUTHENTICATION_CREDENTIALS_ATTRIBUTE
-
equals
Deprecated. -
hashCode
public int hashCode()Deprecated.
-
HttpHeaders.setBasicAuth(String, String)while building the request.