ConcurrentStack<T>.TryPop(T) Méthode
Définition
Important
Certaines informations portent sur la préversion du produit qui est susceptible d’être en grande partie modifiée avant sa publication. Microsoft exclut toute garantie, expresse ou implicite, concernant les informations fournies ici.
Tente de faire apparaître et de renvoyer l’objet en haut du ConcurrentStack<T>.
public:
bool TryPop([Runtime::InteropServices::Out] T % result);
public bool TryPop(out T result);
member this.TryPop : 'T -> bool
Public Function TryPop (ByRef result As T) As Boolean
Paramètres
- result
- T
Lorsque cette méthode retourne, si l’opération a réussi, result contient l’objet supprimé. Si aucun objet n’a été disponible pour être supprimé, la valeur n’est pas spécifiée.
Retours
true si un élément a été supprimé et retourné du haut du fichier ConcurrentStack<T> correctement ; sinon, false.
Remarques
Pour obtenir un exemple de code, consultez ConcurrentStack<T>.