AdlsArrayPool<T>.Return(T[], Boolean) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Synchronous method to return an array to the pool that was previously obtained using the Rent(Int32) method on the same AdlsArrayPool<T> instance
public override void Return (T[] array, bool clearArray = false);
override this.Return : 'T[] * bool -> unit
Public Overrides Sub Return (array As T(), Optional clearArray As Boolean = false)
Parameters
- array
- T[]
A buffer to return to the pool that was previously obtained using the Rent(Int32) method.
- clearArray
- Boolean
Indicates whether the contents of the buffer should be cleared before reuse. If clearArray is set to true, and if the pool will store the buffer to enable subsequent reuse, the Return(T[], Boolean) method will clear the array of its contents so that a subsequent caller using the Rent(Int32) method will not see the content of the previous caller. If clearArray is set to false or if the pool will release the buffer, the array's contents are left unchanged.
Applies to
Azure SDK for .NET