Migration from 4.x
Some features from 4.x are replaced by native language constructs from C# 12 or by API from .NET 8. For instance, OneDimensionalArray
is completely removed in favor of collection literals. FirstOrNone
or FirstOrNull
extension methods are removed in favor of list patterns.
Core library
BufferHelpers
divided into the following classes: CharBuffer
, ByteBuffer
, and Memory
static classes. MemoryAllocator
static class merged with Memory
static class. AllocateAtLeast
and AllocateExactly
static methods are introduced in favor of bool exactSize
parameter.
Removed `AsyncDelegate`` in favor of TaskToAsyncResult.
Some methods in BinaryTransformations
are removed in favor of BinaryPrimitives.ReverseEndianness methods.
Reference<T>
is removed without alternative API as too specific type.
Sequence
static class merged with List
, Collection
, AsyncEnumerable
, and Enumerator
static classes.
DotNext.Generic
namespace is completely removed in favor of static abstract interface members. Now generic constant can be emulated as follows:
public interface IConstant<T>
{
static abstract T Value { get; }
}
Buffers
UnmanagedMemoryAllocator
is replaced by UnmanagedMemory
.
IUnmanagedMemoryOwner
is replaced by IUnmanagedMemory
.
IO
IAsyncBinaryReader
and IAsyncBinaryWriter
interfaces are redesigned to utilize Generic Math features.
Interop Services
AtomicPointer
is completely removed. Use Pointer<T>.Value
instead.
Raft
UDP transport support is completely removed. Use TCP instead.
Reflection
DotNext.Reflection
library is no longer supported and removed. See this announcement.