Class DiscoveryReport

Namespace
Cratis.Chronicle.Discovery
Assembly
Cratis.Chronicle.dll

Represents the artifacts found by the last discovery pass.

public record DiscoveryReport : IEquatable<DiscoveryReport>
Inheritance
DiscoveryReport
Implements
Inherited Members
Extension Methods

Constructors

DiscoveryReport(DiscoveryReport)

protected DiscoveryReport(DiscoveryReport original)

Parameters

original DiscoveryReport

DiscoveryReport(bool, IImmutableList<DiscoveredArtifact>)

Represents the artifacts found by the last discovery pass.

public DiscoveryReport(bool HasRun, IImmutableList<DiscoveredArtifact> Artifacts)

Parameters

HasRun bool

Whether discovery has completed.

Artifacts IImmutableList<DiscoveredArtifact>

The discovered artifacts.

Fields

NotRun

The report before discovery has completed.

public static readonly DiscoveryReport NotRun

Field Value

DiscoveryReport

Properties

Artifacts

The discovered artifacts.

public IImmutableList<DiscoveredArtifact> Artifacts { get; init; }

Property Value

IImmutableList<DiscoveredArtifact>

EqualityContract

protected virtual Type EqualityContract { get; }

Property Value

Type

HasRun

Whether discovery has completed.

public bool HasRun { get; init; }

Property Value

bool

Methods

CountOf(ArtifactKind)

Counts artifacts of a given kind.

public int CountOf(ArtifactKind kind)

Parameters

kind ArtifactKind

The kind to count.

Returns

int

The number of matching artifacts.

Deconstruct(out bool, out IImmutableList<DiscoveredArtifact>)

public void Deconstruct(out bool HasRun, out IImmutableList<DiscoveredArtifact> Artifacts)

Parameters

HasRun bool
Artifacts IImmutableList<DiscoveredArtifact>

Equals(DiscoveryReport?)

Compares reports by value, including their artifact lists.

public virtual bool Equals(DiscoveryReport? other)

Parameters

other DiscoveryReport

The report to compare with.

Returns

bool

Whether both reports carry the same discovery facts.

Equals(object?)

public override bool Equals(object? obj)

Parameters

obj object

Returns

bool

GetHashCode()

public override int GetHashCode()

Returns

int

OfKind(ArtifactKind)

Selects artifacts of a given kind.

public IEnumerable<DiscoveredArtifact> OfKind(ArtifactKind kind)

Parameters

kind ArtifactKind

The kind to select.

Returns

IEnumerable<DiscoveredArtifact>

The matching artifacts.

PrintMembers(StringBuilder)

protected virtual bool PrintMembers(StringBuilder builder)

Parameters

builder StringBuilder

Returns

bool

ToString()

public override string ToString()

Returns

string

Operators

operator ==(DiscoveryReport?, DiscoveryReport?)

public static bool operator ==(DiscoveryReport? left, DiscoveryReport? right)

Parameters

left DiscoveryReport
right DiscoveryReport

Returns

bool

operator !=(DiscoveryReport?, DiscoveryReport?)

public static bool operator !=(DiscoveryReport? left, DiscoveryReport? right)

Parameters

left DiscoveryReport
right DiscoveryReport

Returns

bool