Skip to content

Repository files navigation

Pure.Chart.RelationalModel.Abstractions.Serialization.System

System.Text.Json converters for chart relational model abstractions in the Pure ecosystem.

.NET build & testBuild and DeployNuGetLicense: MIT

Overview

Pure.Chart.RelationalModel.Abstractions.Serialization.System provides System.Text.Json converters that serialize and deserialize the chart relational model interfaces defined in Pure.Chart.RelationalModel.Abstractions. Each interface maps to a custom JsonConverter<T> backed by an internal sealed record that carries [JsonConstructor] for round-trip fidelity.

Converters

ClassConverts
ChartRelationalModelConverterIChartRelationalModel
ChartSeriesRelationalModelConverterIChartSeriesRelationalModel
AxisRelationalModelConverterIAxisRelationalModel
ChartTypeRelationalModelConverterIChartTypeRelationalModel
ChartRelationalModelAbstractionsConvertersEnumerable collection of all four converters above

Design Principles

  • Interface-preserving — converters target abstract interfaces, not concrete types, so any implementation serializes transparently.
  • Internal DTOs — each converter delegates to a private sealed record with [JsonConstructor]; no internal types leak into the public API.

Dependencies

Target Frameworks

  • .NET 7
  • .NET 8
  • .NET 9
  • .NET 10

Installation

dotnet add package Pure.Chart.RelationalModel.Abstractions.Serialization.System

Usage

JsonSerializerOptionsoptions=newJsonSerializerOptions();foreach(JsonConverterconverterinnewChartRelationalModelAbstractionsConverters()){options.Converters.Add(converter);}stringjson=JsonSerializer.Serialize(chart,options);IChartRelationalModeldeserialized=JsonSerializer.Deserialize<IChartRelationalModel>(json,options)!;

About

System.Text.Json converters for chart relational model abstractions in the Pure ecosystem.

Resources

Code of conduct

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages

Generated from kudima03/Pure.Template