C# 클래스 Microsoft.Identity.Client.TokenCache

파일 보기 프로젝트 열기: AzureAD/microsoft-authentication-library-for-dotnet 1 사용 예제들

공개 메소드들

메소드 설명
Clear ( string clientId ) : void

Clears the cache by deleting all the items. Note that if the cache is the default shared cache, clearing it would impact all the instances of PublicClientApplication which share that cache.

Deserialize ( byte state ) : void

Deserializes state of the cache. The state should be the blob received earlier by calling the method Serialize.

ReadItems ( string clientId ) : IEnumerable

Reads a copy of the list of all items in the cache.

Serialize ( ) : byte[]

Serializes current state of the cache as a blob. Caller application can persist the blob and update the state of the cache later by passing that blob back in constructor or by calling method Deserialize.

TokenCache ( byte state ) : System

Constructor receiving state of the cache

비공개 메소드들

메소드 설명
CreateResultExFromCacheResultEx ( TokenCacheKey key, AuthenticationResultEx resultEx ) : AuthenticationResultEx
DeleteItem ( TokenCacheItem item ) : void

Deletes an item from the cache.

DeleteItemFromCache ( TokenCacheItem item ) : void
GetHomeObjectIdsFromCache ( string clientId ) : IEnumerable
GetUniqueIdsFromCache ( string clientId ) : IEnumerable
GetUsers ( string clientId ) : IEnumerable
LoadFromCache ( string authority, HashSet scope, string clientId, User user, string policy, CallState callState ) : AuthenticationResultEx
LoadSingleItemFromCache ( string authority, HashSet scope, string clientId, User user, string policy, CallState callState ) : AuthenticationResultEx>?.KeyValuePair
OnAfterAccess ( TokenCacheNotificationArgs args ) : void
OnBeforeAccess ( TokenCacheNotificationArgs args ) : void
OnBeforeWrite ( TokenCacheNotificationArgs args ) : void
QueryCache ( string authority, string clientId, User user, string policy ) : AuthenticationResultEx>>.List
QueryCache ( string authority, string clientId, string uniqueId, string displayableId, string rootId, string policy ) : AuthenticationResultEx>>.List

Queries all values in the cache that meet the passed in values, plus the authority value that this AuthorizationContext was created with. In every case passing null results in a wildcard evaluation.

ReadItemsFromCache ( string clientId ) : List
StoreToCache ( AuthenticationResultEx resultEx, string authority, string clientId, string policy, bool restrictToSingleUser, CallState callState ) : void
TokenCache ( ) : System
UpdateCachedRefreshTokens ( AuthenticationResultEx result, string authority, string clientId, string policy ) : void

메소드 상세

Clear() 공개 메소드

Clears the cache by deleting all the items. Note that if the cache is the default shared cache, clearing it would impact all the instances of PublicClientApplication which share that cache.
public Clear ( string clientId ) : void
clientId string
리턴 void

Deserialize() 공개 메소드

Deserializes state of the cache. The state should be the blob received earlier by calling the method Serialize.
public Deserialize ( byte state ) : void
state byte State of the cache as a blob
리턴 void

ReadItems() 공개 메소드

Reads a copy of the list of all items in the cache.
public ReadItems ( string clientId ) : IEnumerable
clientId string
리턴 IEnumerable

Serialize() 공개 메소드

Serializes current state of the cache as a blob. Caller application can persist the blob and update the state of the cache later by passing that blob back in constructor or by calling method Deserialize.
public Serialize ( ) : byte[]
리턴 byte[]

TokenCache() 공개 메소드

Constructor receiving state of the cache
public TokenCache ( byte state ) : System
state byte
리턴 System