public final class AuthenticationTokens extends Object
| Modifier and Type | Method and Description |
|---|---|
static <T,C extends com.cloudbees.plugins.credentials.Credentials> |
convert(Class<T> type,
C credentials)
Converts the supplied credentials into the specified token.
|
static <T> com.cloudbees.plugins.credentials.CredentialsMatcher |
matcher(Class<T> tokenClass)
Builds a matcher for credentials that can be converted into the supplied token type.
|
public static <T> com.cloudbees.plugins.credentials.CredentialsMatcher matcher(Class<T> tokenClass)
T - the type of tokentokenClass - the type of token@CheckForNull
public static <T,C extends com.cloudbees.plugins.credentials.Credentials> T convert(@NonNull
Class<T> type,
@CheckForNull
C credentials)
T - the type of token to convert to.C - the type of credentials to convert,type - the type of token to convert to.credentials - the credentials instance to convert.null if the credentials could not be converted.Copyright © 2004-2015. All Rights Reserved.