SecondsFormatter
object type35 methodsavailable in: camelot
Methods
In the emulator: 35 implemented.
| method | what it does | status |
|---|---|---|
CanApproximate | Returns true if the given number of seconds is within an appropriate range for approximated formatting. · warcraft.wiki.gg ↗(seconds: Seconds): boolean | implemented |
CanRoundUpIntervals | Returns true if the formatter can promote values to higher interval bands. · warcraft.wiki.gg ↗(): boolean | implemented |
CanRoundUpLastUnit | Returns true if the formatter should round the final unit up rather than down. · warcraft.wiki.gg ↗(): boolean | implemented |
EvaluateDesiredUnitCount | Returns the unit count that a given number of seconds will use for formatting. · warcraft.wiki.gg ↗(seconds: Seconds): number | implemented |
EvaluateMaxInterval | Returns the maximum interval band that a given number of seconds will use for formatting. · warcraft.wiki.gg ↗(seconds: Seconds): SecondsFormatterInterval | implemented |
EvaluateMinInterval | Returns the minimum interval band that a given number of seconds will use for formatting. · warcraft.wiki.gg ↗(seconds: Seconds): SecondsFormatterInterval | implemented |
Format | Formats a number of seconds and returns the resulting string. · warcraft.wiki.gg ↗(seconds: Seconds, abbreviation: SecondsFormatterAbbreviation?): string | implemented |
FormatZero | Returns formatted string representing a zero second duration. · warcraft.wiki.gg ↗(abbreviation: SecondsFormatterAbbreviation?): string | implemented |
GetApproximationSeconds | Returns the threshold below which numeric values are formatted as approximated strings. · warcraft.wiki.gg ↗(): Seconds | implemented |
GetConvertToLower | Returns true if the formatter should lowercase all unit format strings. · warcraft.wiki.gg ↗(): boolean | implemented |
GetDefaultAbbreviation | Returns the default abbreviation mode used for formatting. · warcraft.wiki.gg ↗(): SecondsFormatterAbbreviation? | implemented |
GetDesiredUnitCount | Returns the desired unit count for formatting. · warcraft.wiki.gg ↗(): number? | implemented |
GetDesiredUnitCountCurve | Returns the desired unit count curve for formatting. · warcraft.wiki.gg ↗(): LuaCurveObject? | implemented |
GetMaxInterval | Returns the maximum interval band permitted for formatting. · warcraft.wiki.gg ↗(): SecondsFormatterInterval? | implemented |
GetMaxIntervalCurve | Returns the maximum interval band curve permitted for formatting. · warcraft.wiki.gg ↗(): LuaCurveObject? | implemented |
GetMillisecondsThreshold | Returns the threshold below which a value will be formatted as a decimal number of seconds with one place for milliseconds (eg. '3.4') · warcraft.wiki.gg ↗(): Seconds | implemented |
GetMinInterval | Returns the minimum interval band permitted for formatting. · warcraft.wiki.gg ↗(): SecondsFormatterInterval? | implemented |
GetMinIntervalCurve | Returns the minimum interval band curve permitted for formatting. · warcraft.wiki.gg ↗(): LuaCurveObject? | implemented |
GetRounding | Returns how fractional seconds are rounded when not displaying milliseconds. · warcraft.wiki.gg ↗(): SecondsFormatterRounding | implemented |
GetStripIntervalWhitespace | Returns the whitespace stripping mode of the formatter. · warcraft.wiki.gg ↗(): SecondsFormatterIntervalWhitespace | implemented |
Reset | Resets all stored configuration of the formatter. · warcraft.wiki.gg ↗() | implemented |
SetApproximationSeconds | Configures the formatter to render numeric values between zero and this value as approximated strings (eg. '< 1m'). · warcraft.wiki.gg ↗(seconds: Seconds) | implemented |
SetCanRoundUpIntervals | Configures the formatter to promote intervals if values are large enough (eg. '60m' -> '1h'). · warcraft.wiki.gg ↗(canRound: boolean) | implemented |
SetCanRoundUpLastUnit | Configures the formatter to round the last formatted unit up, rather than down. · warcraft.wiki.gg ↗(canRound: boolean) | implemented |
SetConvertToLower | Configures the formatter to convert all interval format strings to lowercase. · warcraft.wiki.gg ↗(convert: boolean) | implemented |
SetDefaultAbbreviation | Sets the default abbreviation mode used for formatting. · warcraft.wiki.gg ↗(abbreviation: SecondsFormatterAbbreviation) | implemented |
SetDesiredUnitCount | Sets the desired unit count used for formatting. · warcraft.wiki.gg ↗(count: number) | implemented |
SetDesiredUnitCountCurve | Sets the desired unit count used for formatting to a curve that will be evaluated with seconds values to produce a desired unit count. · warcraft.wiki.gg ↗(curve: LuaCurveObject) | implemented |
SetMaxInterval | Sets the maximum interval band used for formatting. · warcraft.wiki.gg ↗(interval: SecondsFormatterInterval) | implemented |
SetMaxIntervalCurve | Sets the maximum interval band used for formatting to a curve that will be evaluated with seconds values to produce a value matching a SecondsFormatterInterval enum member. · warcraft.wiki.gg ↗(curve: LuaCurveObject) | implemented |
SetMillisecondsThreshold | Sets the threshold below which a value will be formatted as a decimal number of seconds with one place for milliseconds (eg. '3.4') · warcraft.wiki.gg ↗(threshold: Seconds) | implemented |
SetMinInterval | Sets the minimum interval band used for formatting. · warcraft.wiki.gg ↗(interval: SecondsFormatterInterval) | implemented |
SetMinIntervalCurve | Sets the minimum interval band used for formatting to a curve that will be evaluated with seconds values to produce a value matching a SecondsFormatterInterval enum member. · warcraft.wiki.gg ↗(curve: LuaCurveObject) | implemented |
SetRounding | Sets how fractional seconds are rounded when not displaying milliseconds. · warcraft.wiki.gg ↗(rounding: SecondsFormatterRounding) | implemented |
SetStripIntervalWhitespace | Sets the whitespace stripping mode for the formatter. · warcraft.wiki.gg ↗(strip: SecondsFormatterIntervalWhitespace) | implemented |
sources
Methods and inheritance: Blizzard's API documentation (Blizzard_APIDocumentationGenerated) (camelot 1.60.1). Descriptions: warcraft.wiki.gg's API pages, by its contributors, CC BY-SA 4.0 ↗.