本文整理匯總了Java中net.openid.appauth.ClientAuthentication類的典型用法代碼示例。如果您正苦於以下問題:Java ClientAuthentication類的具體用法?Java ClientAuthentication怎麽用?Java ClientAuthentication使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
ClientAuthentication類屬於net.openid.appauth包,在下文中一共展示了ClientAuthentication類的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: performTokenRequest
import net.openid.appauth.ClientAuthentication; //導入依賴的package包/類
@MainThread
private void performTokenRequest(
TokenRequest request,
AuthorizationService.TokenResponseCallback callback) {
ClientAuthentication clientAuthentication;
try {
clientAuthentication = mStateManager.getCurrent().getClientAuthentication();
} catch (ClientAuthentication.UnsupportedAuthenticationMethod ex) {
Log.d(TAG, "Token request cannot be made, client authentication for the token "
+ "endpoint could not be constructed (%s)", ex);
displayNotAuthorized("Client authentication method is unsupported");
return;
}
mAuthService.performTokenRequest(
request,
clientAuthentication,
callback);
}
示例2: performTokenRequest
import net.openid.appauth.ClientAuthentication; //導入依賴的package包/類
@WorkerThread
private void performTokenRequest(TokenRequest request, AuthorizationService.TokenResponseCallback callback) {
ClientAuthentication clientAuthentication;
try {
clientAuthentication = stateManager.getCurrent().getClientAuthentication();
} catch (ClientAuthentication.UnsupportedAuthenticationMethod ex) {
log(String.format("Token request cannot be made, client authentication for the token "
+ "endpoint could not be constructed (%s)", ex));
log("Client authentication method is unsupported");
return;
}
service.performTokenRequest(
request,
clientAuthentication,
callback);
}