Ecng.Serialization 1.0.332

dotnet add package Ecng.Serialization --version 1.0.332
                    
NuGet\Install-Package Ecng.Serialization -Version 1.0.332
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Ecng.Serialization" Version="1.0.332" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Ecng.Serialization" Version="1.0.332" />
                    
Directory.Packages.props
<PackageReference Include="Ecng.Serialization" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Ecng.Serialization --version 1.0.332
                    
#r "nuget: Ecng.Serialization, 1.0.332"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Ecng.Serialization@1.0.332
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Ecng.Serialization&version=1.0.332
                    
Install as a Cake Addin
#tool nuget:?package=Ecng.Serialization&version=1.0.332
                    
Install as a Cake Tool

Ecng.Serialization

A comprehensive serialization library providing JSON serialization and high-performance binary primitives for .NET applications.

Table of Contents

Overview

Ecng.Serialization provides a flexible and efficient serialization framework with the following key features:

  • JSON Serialization: Full-featured JSON serializer with customizable settings
  • Binary Primitives: High-performance SpanWriter and SpanReader for compact binary formats
  • SettingsStorage: Dictionary-based storage system for application settings
  • IPersistable Pattern: Interface-based serialization for custom types
  • Async Support: Asynchronous serialization methods with cancellation token support
  • Extension Methods: Convenient helpers for common serialization tasks

Installation

Add a reference to the Ecng.Serialization assembly in your project.

<PackageReference Include="Ecng.Serialization" Version="x.x.x" />

Quick Start

JSON Serialization

using Ecng.Serialization;

// Create a JSON serializer with default settings
var serializer = JsonSerializer<MyData>.CreateDefault();

// Serialize to file
await using var stream = File.OpenWrite("data.json");
await serializer.SerializeAsync(data, stream, CancellationToken.None);

// Deserialize from file
await using var readStream = File.OpenRead("data.json");
var loaded = await serializer.DeserializeAsync(readStream, CancellationToken.None);

Binary Primitives

using Ecng.Serialization;

// Write binary data
SpanWriter writer = stackalloc byte[256];
writer.WriteInt32(42);
writer.WriteString("hello");
writer.WriteDateTime(DateTime.UtcNow);

// Read binary data
var reader = new SpanReader(writer.GetWrittenSpan());
int number = reader.ReadInt32();
string text = reader.ReadString(5, Encoding.UTF8);
DateTime timestamp = reader.ReadDateTime();

SettingsStorage

using Ecng.Serialization;

// Create and populate settings
var settings = new SettingsStorage();
settings.Set("Host", "localhost");
settings.Set("Port", 8080);
settings.Set("Timeout", TimeSpan.FromSeconds(30));

// Serialize to JSON string
var serializer = JsonSerializer<SettingsStorage>.CreateDefault();
string json = serializer.SaveToString(settings);

// Deserialize from JSON string
var restored = serializer.LoadFromString(json);
string host = restored.GetValue<string>("Host");
int port = restored.GetValue<int>("Port");

Core Concepts

ISerializer Interface

The ISerializer<T> interface is the foundation of the serialization framework:

public interface ISerializer<T>
{
    string FileExtension { get; }
    ValueTask SerializeAsync(T graph, Stream stream, CancellationToken cancellationToken);
    ValueTask<T> DeserializeAsync(Stream stream, CancellationToken cancellationToken);
}

All serializers implement this interface, providing consistent API across different formats.

JSON Serialization

Creating a JSON Serializer

// Default configuration (indented, enums as strings, ignore null values)
var serializer = JsonSerializer<MyClass>.CreateDefault();

// Custom configuration
var customSerializer = new JsonSerializer<MyClass>
{
    Indent = true,                    // Pretty-print JSON
    EnumAsString = true,              // Serialize enums as strings
    NullValueHandling = NullValueHandling.Ignore,  // Omit null values
    Encoding = Encoding.UTF8,         // Text encoding
    BufferSize = 4096                 // Buffer size for I/O
};

JSON Serializer Settings

Property Type Default Description
Indent bool false Format JSON with indentation
EnumAsString bool false Serialize enums as strings instead of numbers
NullValueHandling NullValueHandling Include How to handle null values
Encoding Encoding UTF8 Text encoding for serialization
BufferSize int 1024 Buffer size for stream operations
FillMode bool true Enable fill mode for IPersistable objects
EncryptedAsByteArray bool false Serialize SecureString as byte array

Serialization Examples

Async File Serialization
var serializer = JsonSerializer<OrderBook>.CreateDefault();

// Save to file
await using var file = File.OpenWrite("orderbook.json");
await serializer.SerializeAsync(orderBook, file, CancellationToken.None);

// Load from file
await using var input = File.OpenRead("orderbook.json");
var orderBook = await serializer.DeserializeAsync(input, CancellationToken.None);
Synchronous Serialization
var serializer = JsonSerializer<MyData>.CreateDefault();

// Serialize to byte array
byte[] data = serializer.Serialize(myObject);

// Deserialize from byte array
var restored = serializer.Deserialize(data);

// Serialize to file
serializer.Serialize(myObject, "output.json");

// Deserialize from file
var loaded = serializer.Deserialize("output.json");
String Serialization
var serializer = JsonSerializer<SettingsStorage>.CreateDefault();

// Serialize to string
string json = serializer.SaveToString(settings);

// Deserialize from string
var settings = serializer.LoadFromString(json);

Supported Types

The JSON serializer supports:

  • Primitives: int, long, double, decimal, bool, string, etc.
  • Date/Time: DateTime, DateTimeOffset, TimeSpan
  • Collections: Arrays, List<T>, IEnumerable<T>
  • Special Types: Guid, byte[], SecureString, TimeZoneInfo, Type
  • Custom Types: Types implementing IPersistable or IAsyncPersistable
  • SettingsStorage: Native support for settings dictionary

Binary Serialization

SpanWriter - Writing Binary Data

SpanWriter is a high-performance ref struct for writing primitive types to a span of bytes.

// Allocate buffer on stack
SpanWriter writer = stackalloc byte[1024];

// Write primitive types
writer.WriteByte(255);
writer.WriteSByte(-128);
writer.WriteBoolean(true);
writer.WriteInt16(short.MaxValue);
writer.WriteUInt16(ushort.MaxValue);
writer.WriteInt32(42);
writer.WriteUInt32(100u);
writer.WriteInt64(long.MaxValue);
writer.WriteUInt64(ulong.MaxValue);
writer.WriteSingle(3.14f);
writer.WriteDouble(2.718281828);
writer.WriteDecimal(1234.5678m);

// Write date/time types
writer.WriteDateTime(DateTime.UtcNow);
writer.WriteTimeSpan(TimeSpan.FromHours(1));

// Write strings (requires encoding)
writer.WriteString("Hello, World!", Encoding.UTF8);

// Write GUID
writer.WriteGuid(Guid.NewGuid());

// Write character
writer.WriteChar('A');

// Get written data
ReadOnlySpan<byte> data = writer.GetWrittenSpan();
int bytesWritten = writer.Position;
Big-Endian / Little-Endian
// Little-endian (default, Intel x86/x64)
SpanWriter writerLE = stackalloc byte[256];
writerLE.WriteInt32(0x12345678);  // Bytes: 78 56 34 12

// Big-endian (network byte order)
SpanWriter writerBE = new SpanWriter(buffer, isBigEndian: true);
writerBE.WriteInt32(0x12345678);  // Bytes: 12 34 56 78
Advanced SpanWriter Usage
byte[] buffer = new byte[1024];
var writer = new SpanWriter(buffer);

// Skip bytes (advance position without writing)
writer.Skip(16);

// Write span of bytes directly
ReadOnlySpan<byte> source = stackalloc byte[] { 1, 2, 3, 4, 5 };
writer.WriteSpan(source);

// Write structures (value types)
var header = new PacketHeader { Version = 1, Length = 100 };
writer.WriteStruct(header, Marshal.SizeOf<PacketHeader>());

// Check remaining space
if (!writer.IsFull)
{
    int remaining = writer.Remaining;
    // Write more data
}

// Get position
int currentPos = writer.Position;

SpanReader - Reading Binary Data

SpanReader is a high-performance ref struct for reading primitive types from a span of bytes.

ReadOnlySpan<byte> data = /* your binary data */;
var reader = new SpanReader(data);

// Read primitive types (must match write order)
byte b = reader.ReadByte();
sbyte sb = reader.ReadSByte();
bool flag = reader.ReadBoolean();
short s = reader.ReadInt16();
ushort us = reader.ReadUInt16();
int i = reader.ReadInt32();
uint ui = reader.ReadUInt32();
long l = reader.ReadInt64();
ulong ul = reader.ReadUInt64();
float f = reader.ReadSingle();
double d = reader.ReadDouble();
decimal dec = reader.ReadDecimal();

// Read date/time types
DateTime dt = reader.ReadDateTime();
TimeSpan ts = reader.ReadTimeSpan();

// Read string (must know length)
string text = reader.ReadString(13, Encoding.UTF8);

// Read GUID
Guid id = reader.ReadGuid();

// Read character
char c = reader.ReadChar();

// Check if end of span
if (!reader.End)
{
    int remaining = reader.Remaining;
    // Read more data
}
Advanced SpanReader Usage
var reader = new SpanReader(binaryData);

// Skip bytes
reader.Skip(16);

// Read span of bytes
ReadOnlySpan<byte> chunk = reader.ReadSpan(256);

// Read structure
var header = reader.ReadStruct<PacketHeader>(Marshal.SizeOf<PacketHeader>());

// Read array of structures
var items = new Item[10];
reader.ReadStructArray(items, Marshal.SizeOf<Item>(), 10);

// Get current position
int position = reader.Position;

// Check if at end
bool isEnd = reader.End;
int bytesLeft = reader.Remaining;

Binary Serialization Example

public class BinarySerializer
{
    public byte[] Serialize(TradeData trade)
    {
        byte[] buffer = new byte[256];
        var writer = new SpanWriter(buffer);

        writer.WriteInt64(trade.Id);
        writer.WriteDecimal(trade.Price);
        writer.WriteDecimal(trade.Volume);
        writer.WriteDateTime(trade.Timestamp);
        writer.WriteInt32(trade.Direction);

        return buffer[..writer.Position];
    }

    public TradeData Deserialize(byte[] data)
    {
        var reader = new SpanReader(data);

        return new TradeData
        {
            Id = reader.ReadInt64(),
            Price = reader.ReadDecimal(),
            Volume = reader.ReadDecimal(),
            Timestamp = reader.ReadDateTime(),
            Direction = reader.ReadInt32()
        };
    }
}

SettingsStorage

SettingsStorage is a thread-safe dictionary for storing configuration and settings.

Basic Usage

var settings = new SettingsStorage();

// Set values (fluent API)
settings.Set("ServerUrl", "https://api.example.com")
        .Set("Port", 8080)
        .Set("EnableLogging", true)
        .Set("Timeout", TimeSpan.FromSeconds(30))
        .Set("MaxRetries", 3);

// Get values with type safety
string url = settings.GetValue<string>("ServerUrl");
int port = settings.GetValue<int>("Port");
bool logging = settings.GetValue<bool>("EnableLogging");

// Get values with default
int retries = settings.GetValue("MaxRetries", defaultValue: 5);
string missing = settings.GetValue("NotFound", defaultValue: "default");

// Check if key exists
if (settings.Contains("ServerUrl"))
{
    // Key exists
}

// Get all setting names
IEnumerable<string> names = settings.Names;

Nested Settings

var settings = new SettingsStorage();

// Create nested settings
var database = new SettingsStorage()
    .Set("Host", "localhost")
    .Set("Port", 5432)
    .Set("Database", "myapp");

var logging = new SettingsStorage()
    .Set("Level", "Info")
    .Set("FilePath", "logs/app.log");

settings.Set("Database", database)
        .Set("Logging", logging);

// Retrieve nested settings
var dbSettings = settings.GetValue<SettingsStorage>("Database");
string dbHost = dbSettings.GetValue<string>("Host");

// Or retrieve specific nested value
var logSettings = settings.GetValue<SettingsStorage>("Logging");
string logLevel = logSettings.GetValue<string>("Level");

Async Value Retrieval

var settings = new SettingsStorage();

// Async get with cancellation token
string value = await settings.GetValueAsync<string>(
    "ServerUrl",
    defaultValue: "https://default.com",
    cancellationToken: CancellationToken.None
);

Serializing SettingsStorage

var settings = new SettingsStorage()
    .Set("AppName", "MyApp")
    .Set("Version", "1.0.0");

// Serialize to JSON
var serializer = JsonSerializer<SettingsStorage>.CreateDefault();
string json = serializer.SaveToString(settings);

// Output:
// {
//   "AppName": "MyApp",
//   "Version": "1.0.0"
// }

// Deserialize from JSON
var restored = serializer.LoadFromString(json);

IPersistable Interface

The IPersistable interface enables custom serialization for your types.

Implementing IPersistable

public class TradingStrategy : IPersistable
{
    public string Name { get; set; }
    public decimal StopLoss { get; set; }
    public decimal TakeProfit { get; set; }
    public int MaxPositions { get; set; }
    public TimeSpan HoldingPeriod { get; set; }

    public void Load(SettingsStorage storage)
    {
        Name = storage.GetValue<string>(nameof(Name));
        StopLoss = storage.GetValue<decimal>(nameof(StopLoss));
        TakeProfit = storage.GetValue<decimal>(nameof(TakeProfit));
        MaxPositions = storage.GetValue<int>(nameof(MaxPositions));
        HoldingPeriod = storage.GetValue<TimeSpan>(nameof(HoldingPeriod));
    }

    public void Save(SettingsStorage storage)
    {
        storage.Set(nameof(Name), Name)
               .Set(nameof(StopLoss), StopLoss)
               .Set(nameof(TakeProfit), TakeProfit)
               .Set(nameof(MaxPositions), MaxPositions)
               .Set(nameof(HoldingPeriod), HoldingPeriod);
    }
}

Using IPersistable Objects

var strategy = new TradingStrategy
{
    Name = "Momentum",
    StopLoss = 0.02m,
    TakeProfit = 0.05m,
    MaxPositions = 10,
    HoldingPeriod = TimeSpan.FromHours(24)
};

// Save to SettingsStorage
var settings = strategy.Save();

// Serialize to JSON
var serializer = JsonSerializer<TradingStrategy>.CreateDefault();
await using var file = File.OpenWrite("strategy.json");
await serializer.SerializeAsync(strategy, file, CancellationToken.None);

// Deserialize from JSON
await using var input = File.OpenRead("strategy.json");
var loaded = await serializer.DeserializeAsync(input, CancellationToken.None);

// Clone an object
var clone = strategy.Clone();

// Apply state from one object to another
var newStrategy = new TradingStrategy();
newStrategy.Apply(strategy);

IAsyncPersistable Interface

For asynchronous serialization scenarios:

public class AsyncDataLoader : IAsyncPersistable
{
    public string ConnectionString { get; set; }
    public List<string> LoadedData { get; set; }

    public async Task LoadAsync(SettingsStorage storage, CancellationToken cancellationToken)
    {
        ConnectionString = storage.GetValue<string>(nameof(ConnectionString));

        // Perform async operations
        await Task.Delay(100, cancellationToken);

        var data = storage.GetValue<string[]>(nameof(LoadedData));
        LoadedData = new List<string>(data);
    }

    public async Task SaveAsync(SettingsStorage storage, CancellationToken cancellationToken)
    {
        storage.Set(nameof(ConnectionString), ConnectionString);

        // Perform async operations
        await Task.Delay(100, cancellationToken);

        storage.Set(nameof(LoadedData), LoadedData.ToArray());
    }
}

IPersistable Helper Methods

// Save to SettingsStorage
SettingsStorage settings = myObject.Save();

// Load from SettingsStorage
var obj = new MyClass();
obj.Load(settings);

// Load typed object
var typed = settings.Load<MyClass>();

// Save entire object with type information
var storage = myObject.SaveEntire(isAssemblyQualifiedName: false);

// Load entire object with type creation
var restored = storage.LoadEntire<IPersistable>();

// Clone
var clone = myObject.Clone();

// Async clone
var asyncClone = await myAsyncObject.CloneAsync(CancellationToken.None);

// Apply state from clone
myObject.Apply(clone);

// Async apply
await myAsyncObject.ApplyAsync(clone, CancellationToken.None);

Extension Methods

ISerializer Extensions

var serializer = JsonSerializer<MyData>.CreateDefault();

// Synchronous serialization
byte[] data = serializer.Serialize(myObject);
serializer.Serialize(myObject, "output.json");
serializer.Serialize(myObject, stream);

// Synchronous deserialization
var obj1 = serializer.Deserialize(data);
var obj2 = serializer.Deserialize("input.json");
var obj3 = serializer.Deserialize(stream);

// String serialization
string json = serializer.SaveToString(myObject);
var restored = serializer.LoadFromString(json);

JSON Helper Methods

using Ecng.Serialization;

// Serialize to JSON string
string json = myObject.ToJson(indent: true);

// Deserialize from JSON string
var obj = json.DeserializeObject<MyClass>();

// Create JSON serializer settings
var settings = JsonHelper.CreateJsonSerializerSettings();

// Skip BOM from byte array
byte[] cleanData = jsonBytes.SkipBom();

// Skip BOM from string
string cleanJson = jsonString.SkipBom();

Advanced Features

Custom Serializers

Register custom serializers for specific types:

// Register custom serializer
PersistableHelper.RegisterCustomSerializer<MyType>(
    serialize: obj =>
    {
        var storage = new SettingsStorage();
        storage.Set("CustomField", obj.CustomProperty);
        return storage;
    },
    deserialize: storage =>
    {
        return new MyType
        {
            CustomProperty = storage.GetValue<string>("CustomField")
        };
    }
);

// Use custom serializer
MyType obj = new MyType { CustomProperty = "value" };
if (obj.TrySerialize(out var storage))
{
    // Custom serialization succeeded
}

if (storage.TryDeserialize<MyType>(out var deserialized))
{
    // Custom deserialization succeeded
}

// Unregister custom serializer
PersistableHelper.UnRegisterCustomSerializer<MyType>();

Type Adapters

Register adapters for non-persistable types:

// Register adapter for a type
typeof(MyType).RegisterAdapterType(typeof(MyTypeAdapter));

// Remove adapter
typeof(MyType).RemoveAdapterType();

// Check if adapter exists
if (typeof(MyType).TryGetAdapterType(out Type adapterType))
{
    // Adapter registered
}

Adapter Implementation

public class MyTypeAdapter : IPersistable, IPersistableAdapter
{
    public object UnderlyingValue { get; set; }

    public void Load(SettingsStorage storage)
    {
        var myType = new MyType
        {
            Property = storage.GetValue<string>("Property")
        };
        UnderlyingValue = myType;
    }

    public void Save(SettingsStorage storage)
    {
        var myType = (MyType)UnderlyingValue;
        storage.Set("Property", myType.Property);
    }
}

Tuple Serialization

// Convert tuple to storage
var pair = new RefPair<int, string> { First = 42, Second = "hello" };
var storage = pair.ToStorage();

// Convert storage to tuple
var restored = storage.ToRefPair<int, string>();

// Also supports RefTriple, RefQuadruple, RefFive
var triple = new RefTriple<int, string, bool>
{
    First = 1,
    Second = "two",
    Third = true
};
var tripleStorage = triple.ToStorage();
var restoredTriple = tripleStorage.ToRefTriple<int, string, bool>();

MemberInfo Serialization

using System.Reflection;

// Serialize MemberInfo
MethodInfo method = typeof(MyClass).GetMethod("MyMethod");
var storage = method.ToStorage(isAssemblyQualifiedName: false);

// Deserialize MemberInfo
var restored = storage.ToMember<MethodInfo>();

// Also works with Type, PropertyInfo, FieldInfo, etc.
Type type = typeof(MyClass);
var typeStorage = type.ToStorage();
var restoredType = typeStorage.ToMember<Type>();

Object Serialization

// Serialize any object to storage
object value = 42;
var storage = value.ToStorage(isAssemblyQualifiedName: false);

// Deserialize from storage
object restored = storage.FromStorage();

// Works with IPersistable objects too
var persistable = new MyPersistableClass();
var objStorage = persistable.ToStorage();
var objRestored = objStorage.FromStorage();

Conditional Loading

var obj = new MyPersistableClass();

// Load only if storage is not null
bool loaded = obj.LoadIfNotNull(settings, "MyKey");

// Load from nested setting if exists
if (obj.LoadIfNotNull(settings.GetValue<SettingsStorage>("Nested")))
{
    // Successfully loaded from nested settings
}

File Extension

var serializer = JsonSerializer<MyData>.CreateDefault();

// Get file extension for the format
string ext = serializer.FileExtension;  // Returns "json"

// Use in file operations
string fileName = $"data.{serializer.FileExtension}";

Best Practices

1. Use CreateDefault() for JSON

// Good: Uses sensible defaults (indent, enums as strings, ignore nulls)
var serializer = JsonSerializer<MyData>.CreateDefault();

// Avoid: Manual configuration unless you need specific settings
var serializer = new JsonSerializer<MyData>
{
    Indent = true,
    EnumAsString = true,
    NullValueHandling = NullValueHandling.Ignore
};

2. Prefer Async Methods

// Good: Async for I/O operations
await serializer.SerializeAsync(data, stream, cancellationToken);

// Avoid: Sync methods for file/network I/O
serializer.Serialize(data, stream);  // Only for in-memory streams

3. Use IPersistable for Domain Objects

// Good: Explicit control over serialization
public class Order : IPersistable
{
    public void Load(SettingsStorage storage) { /* ... */ }
    public void Save(SettingsStorage storage) { /* ... */ }
}

// Avoid: Relying on reflection for complex objects

4. Dispose Streams Properly

// Good: Using statement ensures disposal
await using var stream = File.OpenRead("data.json");
var data = await serializer.DeserializeAsync(stream, cancellationToken);

// Avoid: Manual disposal
var stream = File.OpenRead("data.json");
try
{
    var data = await serializer.DeserializeAsync(stream, cancellationToken);
}
finally
{
    stream.Dispose();
}

5. Stack Allocation for Binary

// Good: Stack allocation for small buffers
SpanWriter writer = stackalloc byte[256];
writer.WriteInt32(42);

// Avoid: Heap allocation unless necessary
byte[] buffer = new byte[256];
var writer = new SpanWriter(buffer);

Performance Considerations

Binary Serialization

  • SpanWriter and SpanReader use stack allocation for maximum performance
  • Zero allocation for primitives when using stackalloc
  • No boxing/unboxing
  • Direct memory access

JSON Serialization

  • Configurable buffer sizes for optimal I/O
  • Async methods prevent thread blocking
  • Streaming API for large files
  • Efficient enum handling

SettingsStorage

  • Thread-safe dictionary implementation
  • Case-insensitive key lookup
  • Lazy type conversion
  • Minimal allocations

Error Handling

try
{
    var serializer = JsonSerializer<MyData>.CreateDefault();
    var data = await serializer.DeserializeAsync(stream, cancellationToken);
}
catch (JsonException ex)
{
    // JSON parsing error
    Console.WriteLine($"Invalid JSON: {ex.Message}");
}
catch (InvalidOperationException ex)
{
    // Serialization logic error
    Console.WriteLine($"Serialization error: {ex.Message}");
}
catch (OperationCanceledException)
{
    // Operation was cancelled
    Console.WriteLine("Operation cancelled");
}

Thread Safety

  • SettingsStorage is thread-safe
  • JsonSerializer<T> instances are thread-safe for concurrent reads
  • SpanWriter and SpanReader are ref structs and not thread-safe (use on stack)

License

See the main StockSharp repository for licensing information.

Contributing

Contributions are welcome! Please submit pull requests to the main StockSharp repository.

Support

For issues and questions, please use the StockSharp issue tracker or community forums.

Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 is compatible.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
.NET Core netcoreapp2.0 was computed.  netcoreapp2.1 was computed.  netcoreapp2.2 was computed.  netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.0 is compatible.  netstandard2.1 was computed. 
.NET Framework net461 was computed.  net462 was computed.  net463 was computed.  net47 was computed.  net471 was computed.  net472 was computed.  net48 was computed.  net481 was computed. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen40 was computed.  tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (2)

Showing the top 2 NuGet packages that depend on Ecng.Serialization:

Package Downloads
Ecng.ComponentModel

Ecng system framework

Ecng.Interop.Windows

Ecng system framework

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.0.332 0 1/22/2026
1.0.331 615 1/19/2026
1.0.330 421 1/19/2026
1.0.329 424 1/18/2026
1.0.328 392 1/18/2026
1.0.327 411 1/16/2026
1.0.326 625 1/14/2026
1.0.325 556 1/13/2026
1.0.324 505 1/13/2026
1.0.323 853 1/9/2026
1.0.322 546 1/9/2026
1.0.321 500 1/8/2026
1.0.320 2,502 1/4/2026
1.0.319 539 1/1/2026
1.0.318 499 12/31/2025
1.0.317 495 12/30/2025
1.0.316 487 12/30/2025
1.0.315 510 12/29/2025
1.0.314 923 12/26/2025
1.0.313 519 12/26/2025
1.0.312 509 12/26/2025
1.0.311 525 12/26/2025
1.0.310 598 12/25/2025
1.0.309 602 12/25/2025
1.0.308 1,110 12/22/2025
1.0.307 612 12/21/2025
1.0.306 660 12/19/2025
1.0.305 649 12/19/2025
1.0.304 850 12/17/2025
1.0.303 890 12/15/2025
1.0.302 649 12/15/2025
1.0.301 635 12/14/2025
1.0.300 1,713 12/12/2025
1.0.299 904 12/12/2025
1.0.298 508 12/12/2025
1.0.297 525 12/12/2025
1.0.296 893 12/12/2025
1.0.295 1,227 12/2/2025
1.0.294 1,105 12/2/2025
1.0.293 1,104 12/2/2025
1.0.292 715 11/30/2025
1.0.291 570 11/29/2025
1.0.290 568 11/28/2025
1.0.289 553 11/28/2025
1.0.288 646 11/27/2025
1.0.287 726 11/24/2025
1.0.286 631 11/24/2025
1.0.285 645 11/23/2025
1.0.284 622 11/23/2025
1.0.283 680 11/22/2025
1.0.282 1,746 11/20/2025
1.0.281 903 11/18/2025
1.0.280 840 11/18/2025
1.0.279 863 11/13/2025
1.0.278 763 11/10/2025
1.0.277 1,644 11/1/2025
1.0.276 877 10/28/2025
1.0.275 861 10/27/2025
1.0.274 704 10/27/2025
1.0.273 630 10/25/2025
1.0.272 2,358 10/11/2025
1.0.271 2,063 10/3/2025
1.0.270 2,086 9/28/2025
1.0.269 770 9/25/2025
1.0.268 5,561 9/2/2025
1.0.267 3,189 8/30/2025
1.0.266 817 8/30/2025
1.0.265 1,682 8/19/2025
1.0.264 695 8/15/2025
1.0.263 5,545 7/16/2025
1.0.262 2,009 7/13/2025
1.0.261 641 7/13/2025
1.0.260 647 7/12/2025
1.0.259 1,920 7/8/2025
1.0.258 1,417 7/4/2025
1.0.257 698 7/2/2025
1.0.256 5,457 6/16/2025
1.0.255 838 6/9/2025
1.0.254 727 6/8/2025
1.0.253 2,330 5/21/2025
1.0.252 854 5/17/2025
1.0.251 2,387 5/12/2025
1.0.250 753 5/12/2025
1.0.249 674 5/11/2025
1.0.248 655 5/11/2025
1.0.247 606 5/10/2025
1.0.246 610 5/10/2025
1.0.245 1,354 4/17/2025
1.0.244 751 4/15/2025
1.0.243 681 4/12/2025
1.0.242 4,839 3/22/2025
1.0.241 707 3/20/2025
1.0.240 670 3/20/2025
1.0.239 693 3/19/2025
1.0.238 5,611 2/26/2025
1.0.237 747 2/26/2025
1.0.236 9,208 2/5/2025
1.0.235 4,527 1/21/2025
1.0.234 721 1/20/2025
1.0.233 593 1/20/2025
1.0.232 719 1/19/2025
1.0.231 2,309 1/14/2025
1.0.230 1,080 1/12/2025
1.0.229 664 1/12/2025
1.0.228 680 1/12/2025
1.0.227 816 1/12/2025
1.0.226 1,311 1/10/2025
1.0.225 4,814 12/27/2024
1.0.224 694 12/19/2024
1.0.223 1,162 11/20/2024
1.0.222 4,118 11/18/2024
1.0.221 2,534 11/7/2024
1.0.220 1,088 10/31/2024
1.0.219 986 10/19/2024
1.0.218 3,809 10/12/2024
1.0.217 1,369 10/9/2024
1.0.216 3,803 10/5/2024
1.0.215 5,426 9/18/2024
1.0.214 723 9/17/2024
1.0.213 5,033 9/3/2024
1.0.212 724 9/1/2024
1.0.211 4,530 8/8/2024
1.0.210 11,190 6/12/2024
1.0.209 3,500 5/28/2024
1.0.208 4,330 5/4/2024
1.0.207 2,971 4/23/2024
1.0.206 2,066 4/21/2024
1.0.205 904 4/14/2024
1.0.204 6,277 3/28/2024
1.0.203 840 3/17/2024
1.0.202 4,135 2/23/2024
1.0.201 752 2/23/2024
1.0.200 4,082 2/18/2024
1.0.199 736 2/18/2024
1.0.198 813 2/16/2024
1.0.197 2,847 2/13/2024
1.0.196 2,649 2/8/2024
1.0.195 3,034 2/5/2024
1.0.194 749 2/4/2024
1.0.193 3,152 1/23/2024
1.0.192 731 1/23/2024
1.0.191 2,504 1/12/2024
1.0.190 5,784 1/2/2024
1.0.189 892 12/29/2023
1.0.188 5,543 12/15/2023
1.0.187 1,197 12/15/2023
1.0.186 1,253 12/13/2023
1.0.185 817 12/13/2023
1.0.184 12,379 11/12/2023
1.0.183 1,342 11/10/2023
1.0.182 888 11/10/2023
1.0.181 1,145 11/9/2023
1.0.180 1,949 11/3/2023
1.0.179 873 11/1/2023
1.0.178 932 11/1/2023
1.0.177 26,111 9/8/2023
1.0.176 1,295 9/8/2023
1.0.175 1,455 9/3/2023
1.0.174 1,737 8/21/2023
1.0.173 1,365 8/15/2023
1.0.172 926 8/14/2023
1.0.171 923 8/14/2023
1.0.170 1,522 8/10/2023
1.0.169 40,922 7/1/2023
1.0.168 1,081 6/29/2023
1.0.167 16,451 5/27/2023
1.0.166 1,395 5/21/2023
1.0.165 1,546 5/19/2023
1.0.164 26,832 5/8/2023
1.0.163 3,689 5/1/2023
1.0.162 2,804 4/22/2023
1.0.161 1,371 4/21/2023
1.0.160 51,989 4/3/2023
1.0.159 3,220 3/27/2023
1.0.158 2,778 3/21/2023
1.0.157 3,575 3/13/2023
1.0.156 20,146 3/6/2023
1.0.155 2,461 2/26/2023
1.0.154 17,302 2/21/2023
1.0.153 1,583 2/20/2023
1.0.152 2,970 2/15/2023
1.0.151 1,582 2/14/2023
1.0.150 33,991 2/9/2023
1.0.149 18,117 2/7/2023
1.0.148 2,217 2/4/2023
1.0.147 22,322 2/2/2023
1.0.146 18,501 1/30/2023
1.0.145 7,453 1/18/2023
1.0.144 45,940 12/30/2022
1.0.143 3,403 12/23/2022
1.0.142 22,937 12/12/2022
1.0.141 25,532 12/4/2022
1.0.140 2,451 12/4/2022
1.0.139 3,184 11/30/2022
1.0.138 2,447 11/29/2022
1.0.137 2,479 11/28/2022
1.0.136 6,735 11/18/2022
1.0.135 29,676 11/11/2022
1.0.134 2,440 11/11/2022
1.0.133 2,446 11/10/2022
1.0.132 2,685 11/5/2022
1.0.131 4,012 11/4/2022
1.0.130 26,570 11/1/2022
1.0.129 27,033 10/16/2022
1.0.128 9,681 9/10/2022
1.0.127 53,643 9/8/2022
1.0.126 2,871 9/8/2022
1.0.125 2,823 9/8/2022
1.0.124 2,818 9/4/2022
1.0.123 2,870 9/4/2022
1.0.122 93,162 8/24/2022
1.0.121 9,791 8/8/2022
1.0.120 3,057 8/8/2022
1.0.119 6,236 7/26/2022
1.0.118 3,304 7/26/2022
1.0.117 56,391 7/19/2022
1.0.116 48,654 7/18/2022
1.0.115 8,458 7/8/2022
1.0.114 7,576 6/18/2022
1.0.113 3,303 6/6/2022
1.0.112 100,541 4/30/2022
1.0.111 3,629 4/20/2022
1.0.110 3,606 4/10/2022
1.0.109 3,491 4/7/2022
1.0.108 3,489 4/7/2022
1.0.107 3,606 4/2/2022
1.0.106 15,168 3/29/2022
1.0.105 3,490 3/27/2022
1.0.104 3,517 3/27/2022
1.0.103 292,795 1/24/2022
1.0.102 165,228 12/29/2021
1.0.101 31,401 12/20/2021
1.0.100 4,031 12/13/2021
1.0.99 31,818 12/7/2021
1.0.98 30,586 12/6/2021
1.0.97 2,214 12/6/2021
1.0.96 3,999 12/2/2021
1.0.95 32,134 11/29/2021
1.0.94 30,945 11/22/2021
1.0.93 2,304 11/17/2021
1.0.92 2,248 11/14/2021
1.0.91 31,078 11/13/2021
1.0.90 2,325 11/11/2021
1.0.89 2,278 11/11/2021
1.0.88 2,333 11/10/2021
1.0.87 2,436 11/9/2021
1.0.86 65,383 11/5/2021
1.0.85 2,437 11/5/2021
1.0.84 2,401 11/4/2021
1.0.83 2,284 11/4/2021
1.0.82 2,291 11/3/2021
1.0.81 2,452 10/30/2021
1.0.80 33,963 10/21/2021
1.0.79 2,922 10/17/2021
1.0.78 64,358 10/14/2021
1.0.77 13,819 10/13/2021
1.0.76 2,452 10/12/2021
1.0.75 34,456 10/11/2021
1.0.74 2,289 10/9/2021
1.0.73 37,727 10/7/2021
1.0.72 39,776 10/7/2021
1.0.71 2,381 10/7/2021
1.0.70 2,390 10/6/2021
1.0.69 2,418 9/28/2021
1.0.68 36,737 9/23/2021
1.0.67 2,591 9/11/2021
1.0.66 2,093 9/10/2021
1.0.65 2,108 9/9/2021
1.0.64 2,056 9/8/2021
1.0.63 2,057 9/8/2021
1.0.62 33,467 9/6/2021
1.0.61 2,274 8/31/2021
1.0.60 2,247 8/30/2021
1.0.59 36,301 7/31/2021
1.0.58 62,897 7/30/2021
1.0.57 2,744 7/26/2021
1.0.56 93,014 7/5/2021
1.0.55 2,638 7/1/2021
1.0.54 66,034 6/4/2021
1.0.53 94,550 4/26/2021
1.0.52 33,890 4/19/2021
1.0.51 154,212 4/7/2021
1.0.50 33,236 4/3/2021
1.0.49 183,369 3/22/2021
1.0.48 116,286 3/4/2021
1.0.47 36,218 2/26/2021
1.0.46 171,917 2/2/2021
1.0.45 60,338 1/26/2021
1.0.44 59,666 1/24/2021
1.0.43 2,896 1/24/2021
1.0.42 3,060 1/23/2021
1.0.41 61,050 1/20/2021
1.0.40 3,041 1/20/2021
1.0.39 31,761 1/18/2021
1.0.38 2,966 1/18/2021
1.0.37 30,784 1/16/2021
1.0.36 121,956 12/16/2020
1.0.35 58,624 12/14/2020
1.0.34 36,200 12/9/2020
1.0.33 5,335 12/6/2020
1.0.32 3,522 12/2/2020
1.0.31 3,406 12/2/2020
1.0.30 31,829 12/1/2020
1.0.29 189,256 11/12/2020
1.0.29-atestpub 1,612 11/11/2020
1.0.28 32,973 10/11/2020
1.0.27 114,884 9/9/2020
1.0.26 31,400 9/3/2020
1.0.25 31,957 8/20/2020
1.0.24 87,585 8/9/2020
1.0.23 32,195 7/28/2020
1.0.22 31,239 7/19/2020
1.0.21 58,534 7/6/2020
1.0.20 87,916 6/6/2020
1.0.19 32,589 6/4/2020
1.0.18 59,994 5/29/2020
1.0.17 59,819 5/21/2020
1.0.16 4,115 5/17/2020
1.0.15 60,613 5/12/2020
1.0.14 117,776 5/4/2020
1.0.13 8,215 4/24/2020
1.0.12 10,792 4/22/2020
1.0.11 3,916 4/22/2020
1.0.10 3,935 4/21/2020
1.0.9 34,160 4/18/2020
1.0.8 32,027 4/16/2020
1.0.7 3,799 4/16/2020
1.0.6 27,278 4/15/2020
1.0.5 29,926 4/11/2020
1.0.4 28,739 4/3/2020
1.0.3 3,456 4/1/2020
1.0.2 15,147 3/27/2020
1.0.1 14,131 3/22/2020
1.0.0 6,013 3/22/2020