public class TokenCredentials extends Object implements Credentials
AuthenticationProvider that requires Tokens, such as OAuth2 or JWT
to perform its authentication| Modifier | Constructor and Description |
|---|---|
protected |
TokenCredentials() |
|
TokenCredentials(JsonObject jsonObject) |
|
TokenCredentials(String token) |
| Modifier and Type | Method and Description |
|---|---|
<V> void |
checkValid(V arg)
Implementors should override this method to perform validation.
|
String |
getToken() |
TokenCredentials |
setToken(String token) |
JsonObject |
toJson()
Simple interop to downcast back to JSON for backwards compatibility.
|
String |
toString() |
protected TokenCredentials()
public TokenCredentials(String token)
public TokenCredentials(JsonObject jsonObject)
public String getToken()
public TokenCredentials setToken(String token)
public <V> void checkValid(V arg)
throws CredentialValidationException
CredentialscheckValid in interface CredentialsV - the generic type of the argumentarg - optional argument or null.CredentialValidationException - when the validation failspublic JsonObject toJson()
CredentialstoJson in interface CredentialsCopyright © 2020 Eclipse. All rights reserved.