Table of Contents

Class DispatchCenterCustomEquipment

Namespace
XENBIT.ResQueServe.Core.Models
Assembly
RQS.Core.dll
public record DispatchCenterCustomEquipment : IDispatchCenterCustomEquipment, IEquatable<DispatchCenterCustomEquipment>
Inheritance
DispatchCenterCustomEquipment
Implements
Inherited Members
Extension Methods

Constructors

DispatchCenterCustomEquipment()

public DispatchCenterCustomEquipment()

DispatchCenterCustomEquipment(DispatchCenterCustomEquipment)

protected DispatchCenterCustomEquipment(DispatchCenterCustomEquipment original)

Parameters

original DispatchCenterCustomEquipment

Properties

EqualityContract

protected virtual Type EqualityContract { get; }

Property Value

Type

Id

public long Id { get; set; }

Property Value

long

Number

The slot number used for this equipment, ranging from 1 to 20. Each number is unique within the command center.

public int Number { get; set; }

Property Value

int

Text

The display name of the equipment.

public string Text { get; set; }

Property Value

string

Methods

Equals(object?)

public override bool Equals(object? obj)

Parameters

obj object

Returns

bool

Equals(DispatchCenterCustomEquipment?)

public virtual bool Equals(DispatchCenterCustomEquipment? other)

Parameters

other DispatchCenterCustomEquipment

Returns

bool

GetCustomUnitEquipment()

Calculates the corresponding UnitEquipment enum index based on the custom number assigned.

public UnitEquipment? GetCustomUnitEquipment()

Returns

UnitEquipment?

A nullable UnitEquipment representing the custom equipment or null if the number is outside the valid range.

Exceptions

InvalidOperationException

Thrown when the

        <pre><code class="lang-csharp">Number is >= 1 and <= 20</code></pre>

        .

GetHashCode()

public override int GetHashCode()

Returns

int

PrintMembers(StringBuilder)

protected virtual bool PrintMembers(StringBuilder builder)

Parameters

builder StringBuilder

Returns

bool

ToString()

public override string ToString()

Returns

string

Operators

operator ==(DispatchCenterCustomEquipment?, DispatchCenterCustomEquipment?)

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

Parameters

left DispatchCenterCustomEquipment
right DispatchCenterCustomEquipment

Returns

bool

operator !=(DispatchCenterCustomEquipment?, DispatchCenterCustomEquipment?)

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

Parameters

left DispatchCenterCustomEquipment
right DispatchCenterCustomEquipment

Returns

bool