Struct WorkspaceLockInfo

Namespace
Kuestenlogik.Bowire.Workspace.Git
Assembly
Kuestenlogik.Bowire.Workspace.Git.dll

Snapshot of a workspace lock holder's metadata — populated when AcquireAsync(string, string, CancellationToken) hits an active lock and surfaced on Holder, plus returned from Inspect(string) for diagnostic CLIs.

public readonly struct WorkspaceLockInfo : IEquatable<WorkspaceLockInfo>
Implements
Inherited Members

Constructors

WorkspaceLockInfo(int, string, string, DateTimeOffset)

Snapshot of a workspace lock holder's metadata — populated when AcquireAsync(string, string, CancellationToken) hits an active lock and surfaced on Holder, plus returned from Inspect(string) for diagnostic CLIs.

public WorkspaceLockInfo(int Pid, string Writer, string Host, DateTimeOffset StartedAtUtc)

Parameters

Pid int

OS process id of the holder.

Writer string

Free-form holder tag (e.g. workbench, cli).

Host string

Machine name the holder reported via MachineName.

StartedAtUtc DateTimeOffset

When the holder acquired the lock.

Properties

Host

Machine name the holder reported via MachineName.

public string Host { get; init; }

Property Value

string

Pid

OS process id of the holder.

public int Pid { get; init; }

Property Value

int

StartedAtUtc

When the holder acquired the lock.

public DateTimeOffset StartedAtUtc { get; init; }

Property Value

DateTimeOffset

Writer

Free-form holder tag (e.g. workbench, cli).

public string Writer { get; init; }

Property Value

string

Methods

Deconstruct(out int, out string, out string, out DateTimeOffset)

public void Deconstruct(out int Pid, out string Writer, out string Host, out DateTimeOffset StartedAtUtc)

Parameters

Pid int
Writer string
Host string
StartedAtUtc DateTimeOffset

Equals(WorkspaceLockInfo)

public bool Equals(WorkspaceLockInfo other)

Parameters

other WorkspaceLockInfo

Returns

bool

Equals(object)

public override bool Equals(object obj)

Parameters

obj object

Returns

bool

GetHashCode()

public override int GetHashCode()

Returns

int

ToString()

public override string ToString()

Returns

string

Operators

operator ==(WorkspaceLockInfo, WorkspaceLockInfo)

public static bool operator ==(WorkspaceLockInfo left, WorkspaceLockInfo right)

Parameters

left WorkspaceLockInfo
right WorkspaceLockInfo

Returns

bool

operator !=(WorkspaceLockInfo, WorkspaceLockInfo)

public static bool operator !=(WorkspaceLockInfo left, WorkspaceLockInfo right)

Parameters

left WorkspaceLockInfo
right WorkspaceLockInfo

Returns

bool