Table of Contents

Class SnapshotWriter

Namespace
JD.Domain.Snapshot
Assembly
JD.Domain.Snapshot.dll

Writes domain snapshots to canonical JSON format.

public sealed class SnapshotWriter
Inheritance
SnapshotWriter
Inherited Members

Constructors

SnapshotWriter(SnapshotOptions?)

Initializes a new instance of the SnapshotWriter class.

public SnapshotWriter(SnapshotOptions? options = null)

Parameters

options SnapshotOptions

The snapshot options.

Methods

CreateSnapshot(DomainManifest)

Creates a snapshot from a manifest.

public DomainSnapshot CreateSnapshot(DomainManifest manifest)

Parameters

manifest DomainManifest

The manifest to snapshot.

Returns

DomainSnapshot

The created snapshot with computed hash.

Serialize(DomainSnapshot)

Serializes a snapshot to JSON.

public string Serialize(DomainSnapshot snapshot)

Parameters

snapshot DomainSnapshot

The snapshot to serialize.

Returns

string

The JSON string.

SerializeManifest(DomainManifest)

Serializes a manifest directly to canonical JSON.

public string SerializeManifest(DomainManifest manifest)

Parameters

manifest DomainManifest

The manifest to serialize.

Returns

string

The canonical JSON string.