Partager via


Méthode SecurityTokenCache.TryReplaceEntry

Attempts to replace an existing entry in the cache with a new one.

Espace de noms: Microsoft.IdentityModel.Tokens
Assembly : Microsoft.IdentityModel (dans microsoft.identitymodel.dll)

Utilisation

    Dim instance As SecurityTokenCache
Dim key As Object
Dim newValue As SecurityToken
Dim returnValue As Boolean

returnValue = instance.TryReplaceEntry(key, newValue)

Syntaxe

'Déclaration
Public MustOverride Function TryReplaceEntry ( _
    key As Object, _
    newValue As SecurityToken _
) As Boolean
public abstract bool TryReplaceEntry (
    Object key,
    SecurityToken newValue
)
public:
virtual bool TryReplaceEntry (
    Object^ key, 
    SecurityToken^ newValue
) abstract
public abstract boolean TryReplaceEntry (
    Object key, 
    SecurityToken newValue
)
public abstract function TryReplaceEntry (
    key : Object, 
    newValue : SecurityToken
) : boolean

Paramètres

  • key
    The key of the entry to be retrieved.
  • newValue
    The SecurityToken which will replace the entry associated with the key.

Valeur de retour

A boolean indicating success or failure.

Exceptions

Type d'exception Condition

Cohérence de thread

Tous les membres statiques publics (partagés dans Visual Basic) de ce type sont thread-safe.Il n'est pas garanti que les membres d'instance soient thread-safe.

Plateformes

Plateformes de développement

Windows Server 2003, Windows Vista

Target Platforms

Windows Server 2008, Windows Vista, Not tested on Windows XP

Voir aussi

Référence

Classe SecurityTokenCache
Membres SecurityTokenCache
Espace de noms Microsoft.IdentityModel.Tokens