posts - 19 , comments - 8 , trackbacks - 0

ArrayPool

Array pooling in C#
Introduction The following class reduces garbage collection by maintaining a pool of allocated arrays. DisposableValue I wanted a simple way to manage the lifetime of the arrays. To do this I have borrowed an idea from reactive extensions using System; namespace JetBlack.Common { public class DisposableValue<T> : IDisposable { private readonly Action _dispose; public DisposableValue(T value, Action dispose) { _dispose = dispose; Value = value; } public T Value { get; private set; } public void ......

Posted On Thursday, December 18, 2014 3:57 PM | Comments (1) | Filed Under [ C# array ArrayPool ]

Powered by: