Class OAuth2PasswordGrantRequest
- java.lang.Object
-
- org.springframework.security.oauth2.client.endpoint.AbstractOAuth2AuthorizationGrantRequest
-
- org.springframework.security.oauth2.client.endpoint.OAuth2PasswordGrantRequest
-
public class OAuth2PasswordGrantRequest extends AbstractOAuth2AuthorizationGrantRequest
An OAuth 2.0 Resource Owner Password Credentials Grant request that holds the resource owner's credentials.- Since:
- 5.2
- See Also:
AbstractOAuth2AuthorizationGrantRequest
, Section 1.3.3 Resource Owner Password Credentials
-
-
Constructor Summary
Constructors Constructor Description OAuth2PasswordGrantRequest(ClientRegistration clientRegistration, java.lang.String username, java.lang.String password)
Constructs anOAuth2PasswordGrantRequest
using the provided parameters.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getPassword()
Returns the resource owner's password.java.lang.String
getUsername()
Returns the resource owner's username.-
Methods inherited from class org.springframework.security.oauth2.client.endpoint.AbstractOAuth2AuthorizationGrantRequest
getClientRegistration, getGrantType
-
-
-
-
Constructor Detail
-
OAuth2PasswordGrantRequest
public OAuth2PasswordGrantRequest(ClientRegistration clientRegistration, java.lang.String username, java.lang.String password)
Constructs anOAuth2PasswordGrantRequest
using the provided parameters.- Parameters:
clientRegistration
- the client registrationusername
- the resource owner's usernamepassword
- the resource owner's password
-
-