你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

SharedTokenCacheCredential Class

  • java.lang.Object
    • com.azure.identity.SharedTokenCacheCredential

Implements

@Deprecated
public class SharedTokenCacheCredential
implements TokenCredential

Note

This class has been deprecated. This credential was originally created to support authentication with Visual Studio. Since Visual Studio was the only application that wrote to this token cache, this credential has been deprecated in favor of other developer credentials like AzureCliCredential, AzureDeveloperCliCredential, AzurePowerShellCredential, or IntelliJCredential for local development scenarios.

A credential provider that provides token credentials from the MSAL shared token cache. Requires a username and client ID. If a username is not provided, then the AZURE_USERNAME environment variable will be used.

This credential is a legacy mechanism for authenticating clients using credentials provided to Visual Studio.

Method Summary

Modifier and Type Method and Description
Mono<AccessToken> getToken(TokenRequestContext request)

Gets token from shared token cache

Methods inherited from java.lang.Object

Method Details

getToken

public Mono<AccessToken> getToken(TokenRequestContext request)

Gets token from shared token cache

Parameters:

request

Applies to