public interface Locksmith
| Modifier and Type | Method and Description |
|---|---|
<T> T |
create(String user,
String password)
Cria um nova chave se os dados recebidos forem validos.
|
String |
getUserByToken(String token)
Retorna o nome do usuario ao qual a chave pertence.
|
void |
invalidate(String key)
Destroy a chave com o token/usuario recebido como parametro.
|
Boolean |
isValid(String token)
Valida se a chave esta valido
|
<T> T create(@NotNull
String user,
@NotNull
String password)
throws CredentialNotFoundException
T - type of returnuser - usuáriopassword - senhaCredentialNotFoundException - caso usuario/senha não existam ou sejam incompativeisvoid invalidate(@NotNull
String key)
key - usuario ou token que terá a sessão encerradaBoolean isValid(@NotNull String token)
token - token a ser validadoCopyright © 2018. All rights reserved.