Summary
Never
will cause pooled collections to never clear user types before returning them to the pool.
You might want to use this setting in a .NET Standard project when you know that a particular collection stores only value types and you want the performance benefit of not taking time to reset array items to their default value.
Be careful with this setting: if used for a collection that contains reference types, or value types that contain reference types, this setting could cause memory issues by making the garbage collector unable to clean up instances that are still being referenced by arrays sitting in the ArrayPool.
- Namespace
- Avalonia
.Collections .Pooled - Containing Type
- ClearMode
Syntax
Never
Constant Value
Value | Type |
---|---|
2 | Int32 |