Table of Contents

Class CorrelationId

Namespace
Excalibur.Dispatch
Assembly
Excalibur.Dispatch.Abstractions.dll

Default implementation of ICorrelationId.

public sealed class CorrelationId : ICorrelationId, IEquatable<CorrelationId>
Inheritance
CorrelationId
Implements
Inherited Members
Extension Methods

Constructors

CorrelationId()

Initializes a new instance of the CorrelationId class with a new GUID value.

public CorrelationId()

CorrelationId(Guid)

Initializes a new instance of the CorrelationId class with the specified GUID value.

public CorrelationId(Guid value)

Parameters

value Guid

The GUID value for the correlation identifier.

CorrelationId(string?)

Initializes a new instance of the CorrelationId class with the specified string value.

public CorrelationId(string? value)

Parameters

value string

The string representation of the GUID value.

Exceptions

ArgumentException

Thrown when the value is null or whitespace.

FormatException

Thrown when the value cannot be parsed as a GUID.

Properties

Value

Gets or sets the correlation identifier value.

public Guid Value { get; set; }

Property Value

Guid

The GUID used to correlate related operations.

Methods

Equals(CorrelationId?)

Determines whether the specified CorrelationId is equal to the current instance.

public bool Equals(CorrelationId? other)

Parameters

other CorrelationId

The CorrelationId to compare.

Returns

bool

true if the specified CorrelationId is equal to the current instance; otherwise, false.

Equals(object?)

Determines whether the specified object is equal to the current instance.

public override bool Equals(object? obj)

Parameters

obj object

The object to compare.

Returns

bool

true if the specified object is equal to the current instance; otherwise, false.

GetHashCode()

Returns the hash code for this instance.

public override int GetHashCode()

Returns

int

A 32-bit signed integer hash code.

ToString()

Represents a globally unique identifier (GUID).

public override string ToString()

Returns

string