Table of Contents

Class StringParameterTemplate.StringParameterValue

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

Constructors

StringParameterValue(string?, string[]?, ParameterValueType)

public StringParameterValue(string? value, string[]? list, ParameterValueType valType)

Parameters

value string
list string[]
valType ParameterValueType

StringParameterValue(string?, ParameterValueType, string?)

public StringParameterValue(string? value, ParameterValueType valType, string? display)

Parameters

value string
valType ParameterValueType
display string

StringParameterValue(string?, StringParameterTemplate, string?)

public StringParameterValue(string? value, StringParameterTemplate template, string? display)

Parameters

value string
template StringParameterTemplate
display string

StringParameterValue(StringParameterTemplate)

public StringParameterValue(StringParameterTemplate template)

Parameters

template StringParameterTemplate

Methods

Equals(QuestParameterValue<string>?)

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

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

Parameters

other QuestParameterValue<string>

An object to compare with this object.

Returns

bool

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

Equals(StringParameterValue)

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

public bool Equals(StringParameterTemplate.StringParameterValue other)

Parameters

other StringParameterTemplate.StringParameterValue

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 string GetSingleValue()

Returns

string

Exceptions

InvalidOperationException

Inclusive selection is not supported when getting a single value.

IsMatch(string)

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

public override bool IsMatch(string otherValue)

Parameters

otherValue string

Returns

bool

ToString()

Convert a parameter value back to a string.

public override string ToString()

Returns

string

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

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

Parameters

str ReadOnlySpan<char>
value QuestParameterValue<string>

Returns

bool