Class UsernamePasswordCredentials
java.lang.Object
io.micronaut.security.authentication.UsernamePasswordCredentials
- All Implemented Interfaces:
AuthenticationRequest<String,,String> Serializable
@Introspected
public class UsernamePasswordCredentials
extends Object
implements Serializable, AuthenticationRequest<String,String>
- Since:
- 1.0
- Author:
- Sergio del Amo
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionEmpty constructor.UsernamePasswordCredentials(String username, String password) -
Method Summary
Modifier and TypeMethodDescriptionbooleanpassword getter.Returns password conforming toAuthenticationRequestblueprint.username getter.inthashCode()voidsetPassword(String password) password setter.voidsetUsername(String username) username setter.
-
Constructor Details
-
UsernamePasswordCredentials
public UsernamePasswordCredentials()Empty constructor. -
UsernamePasswordCredentials
- Parameters:
username- e.g. adminpassword- raw password
-
-
Method Details
-
getUsername
username getter.- Returns:
- e.g. admin
-
setUsername
username setter.- Parameters:
username- e.g. admin
-
getPassword
password getter.- Returns:
- raw password
-
setPassword
password setter.- Parameters:
password- raw password
-
getIdentity
- Specified by:
getIdentityin interfaceAuthenticationRequest<String,String> - Returns:
- The token in the request
-
getSecret
Returns password conforming toAuthenticationRequestblueprint.- Specified by:
getSecretin interfaceAuthenticationRequest<String,String> - Returns:
- secret string.
-
equals
-
hashCode
public int hashCode()
-