24 lines
660 B
C#
24 lines
660 B
C#
using System.Text.Json;
|
|
using System.Text.Json.Serialization;
|
|
|
|
namespace View_by_Distance.Metadata.Models.Stateless.Methods;
|
|
|
|
internal record Record(string Name,
|
|
bool HasError,
|
|
List<string> Errors,
|
|
Dictionary<int, MetadataExtractorTag> Tags)
|
|
{
|
|
|
|
public override string ToString()
|
|
{
|
|
string result = JsonSerializer.Serialize(this, RecordSourceGenerationContext.Default.Record);
|
|
return result;
|
|
}
|
|
|
|
}
|
|
|
|
[JsonSourceGenerationOptions(WriteIndented = true)]
|
|
[JsonSerializable(typeof(Record))]
|
|
internal partial class RecordSourceGenerationContext : JsonSerializerContext
|
|
{
|
|
} |