IPooledObjectPolicy<T>.Return(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.
Exécute un certain traitement lorsqu’un objet a été retourné au pool. Peut être utilisé pour réinitialiser l’état d’un objet et indiquer si l’objet doit être retourné au pool.
public:
bool Return(T obj);
public bool Return(T obj);
abstract member Return : 'T -> bool
Public Function Return (obj As T) As Boolean
Paramètres
- obj
- T
Objet à retourner au pool.
Retours
true si l’objet doit être retourné au pool.
false s’il n’est pas possible/souhaitable que le pool conserve l’objet.