Kind: Service
Source: Pams/Data/Pams.Data/Pams.Data.csproj (line 1)
Part of: Pams
NuGet package dependency
System.Runtime.Serialization is a NuGet package dependency declared by Pams.Data.csproj. It lets Pams.Data reference .NET serialization APIs when code reads or writes legacy serialized data.
Diagram
mermaidsequenceDiagram participant DataCode as Pams.Data code participant Project as Pams.Data.csproj participant Package as System.Runtime.Serialization participant Runtime as .NET runtime DataCode->>Project: Build Pams.Data Project->>Package: Resolve PackageReference Package->>Runtime: Load serialization APIs DataCode->>Runtime: Serialize or deserialize legacy data
Usage
tsimport { execFileSync } from "node:child_process";
import { readFileSync } from "node:fs";
import { resolve } from "node:path";
const projectPath = resolve("Pams/Data/Pams.Data/Pams.Data.csproj");
const projectFile = readFileSync(projectPath, "utf8");
if (!projectFile.includes('System.Runtime.Serialization')) {
throw new Error(
"Pams.Data.csproj must reference System.Runtime.Serialization.",
);
}
execFileSync("dotnet", ["build", projectPath], {
stdio: "inherit",
});
AI Coding Instructions
- Keep the
System.Runtime.Serializationpackage reference inPams.Data.csprojwhen editing code that depends on serialization APIs. - Check existing serialization and deserialization paths before changing data contracts or serialized types.
- Treat serialized legacy data as a compatibility boundary; avoid changing formats without validating existing stored payloads.
- Restore and build the
Pams.Dataproject after package or project-file changes.
Was this page helpful?