StringLowerExtensions extension

Lower priority string: truncate with ellipsis, pad, repeat, isWhitespaceOnly. Roadmap #231-234, 391-395.

on

Properties

isWhitespaceOnly bool

Available on String, provided by the StringLowerExtensions extension

True if this string is non-empty and contains only whitespace.
no setter

Methods

ensurePrefix(String prefix) String

Available on String, provided by the StringLowerExtensions extension

Returns this string with prefix prepended if not already present.
ensureSuffix(String suffix) String

Available on String, provided by the StringLowerExtensions extension

Returns this string with suffix appended if not already present.
padLeftTo(int length, [String pad = ' ']) String

Available on String, provided by the StringLowerExtensions extension

Pads this string on the left to length with pad.
padRightTo(int length, [String pad = ' ']) String

Available on String, provided by the StringLowerExtensions extension

Pads this string on the right to length with pad.
removePrefix(String prefix) String

Available on String, provided by the StringLowerExtensions extension

Removes prefix from the start if present; otherwise returns this.
removeSuffix(String suffix) String

Available on String, provided by the StringLowerExtensions extension

Removes suffix from the end if present; otherwise returns this.
repeatTimes(int n) String

Available on String, provided by the StringLowerExtensions extension

Returns this string repeated n times, or empty if n <= 0.