Table of Contents

Class EnumParameterTemplate<TEnum>.EnumParameterValue

Namespace
Uncreated.Warfare.Quests.Parameters
Assembly
Uncreated.Warfare.dll
[JsonConverter(typeof(QuestParameterConverter))]
protected class EnumParameterTemplate<TEnum>.EnumParameterValue : QuestParameterValue<TEnum>, IFormattable, IEquatable<QuestParameterValue<TEnum>>, IEquatable<EnumParameterTemplate<TEnum>.EnumParameterValue>
Inheritance
EnumParameterTemplate<TEnum>.EnumParameterValue
Implements
Inherited Members
Extension Methods

Constructors

EnumParameterValue(EnumParameterTemplate<TEnum>)

public EnumParameterValue(EnumParameterTemplate<TEnum> template)

Parameters

template EnumParameterTemplate<TEnum>

Methods

Equals(EnumParameterValue?)

Indicates whether the current object is equal to another object of the same type.

public bool Equals(EnumParameterTemplate<TEnum>.EnumParameterValue? other)

Parameters

other EnumParameterTemplate<TEnum>.EnumParameterValue

An object to compare with this object.

Returns

bool

true if the current object is equal to the other parameter; otherwise, false.

Equals(QuestParameterValue<TEnum>?)

Indicates whether the current object is equal to another object of the same type.

public override bool Equals(QuestParameterValue<TEnum>? other)

Parameters

other QuestParameterValue<TEnum>

An object to compare with this object.

Returns

bool

true if the current object is equal to the other parameter; otherwise, false.

GetDisplayString(ITranslationValueFormatter)

Creates a string for use in translations.

public override object GetDisplayString(ITranslationValueFormatter formatter)

Parameters

formatter ITranslationValueFormatter

Returns

object

GetSingleValue()

Get one value to use. Must either be a constant or selective.

public override TEnum GetSingleValue()

Returns

TEnum

Exceptions

InvalidOperationException

Inclusive selection is not supported when getting a single value.

IsMatch(TEnum)

Compare a value against the current value of this parameter. Best used with inclusive selection.

public override bool IsMatch(TEnum otherValue)

Parameters

otherValue TEnum

Returns

bool

ToString()

Convert a parameter value back to a string.

public override string ToString()

Returns

string

TryParse(ReadOnlySpan<char>, out QuestParameterValue<TEnum>)

public static bool TryParse(ReadOnlySpan<char> str, out QuestParameterValue<TEnum> value)

Parameters

str ReadOnlySpan<char>
value QuestParameterValue<TEnum>

Returns

bool