Table of Contents

Core

Methods Properties Base Classes Derived Classes
Compare All
CompareTo Begin
ComputeRuneCount ByteCount
Concatenate Count
Contains Empty
EndsWith End
FindFirstOf IsNotEmpty
FindLastOf
FindRangeExclusive
FindRangeInclusive
FormatC
FromRune
Get
IsNullOrEmpty
IsNullOrWhitespace
Join
Replace
RuneIteratorFromByteIndex
RuneIteratorFromRuneIndex
Split
StartsWith
SubString
SubStringBytes
SubStringFromRuneIndices
ToLower
ToUpper
Trim
TrimEnd
TrimStart

Properties


All : stringrange

read-only

Converts the string into a string range.

var All : StringRange

Begin : runeiterator

read-only

Returns the RuneIterator at the start of this string.

var Begin : RuneIterator

ByteCount : integer

read-only

Returns the number of bytes in the string.

var ByteCount : Integer

Count : integer

read-only

Returns the number of bytes in the string.

var Count : Integer

Empty : boolean

read-only

Returns true if the string is emtpy.

var Empty : Boolean

End : runeiterator

read-only

Returns the RuneIterator at the end (one past the last Rune) of this string.

var End : RuneIterator

IsNotEmpty : boolean

read-only

Returns true if the string is not empty.

var IsNotEmpty : Boolean

Methods


Compare : integer

static

Compares the two strings and returns an integer to denote their relative sort order. |Name|Type|Description| |---|---|---| |left|string| | |right|string| |

function Compare(left : String, right : String) : Integer

CompareTo : integer

Compares this string to the given string and returns an integer to denote their relative sort order. |Name|Type|Description| |---|---|---| |p0|stringrange| |

function CompareTo(p0 : StringRange) : Integer

ComputeRuneCount : integer

Compute the number of runes in the string. |Name|Type|Description| |---|---|---|

function ComputeRuneCount() : Integer

Concatenate : string

static

Combines the two strings into a new string. |Name|Type|Description| |---|---|---| |p0|string| | |p1|string| |

function Concatenate(p0 : String, p1 : String) : String

Concatenate : string

static

Combines the two string ranges into a new string. |Name|Type|Description| |---|---|---| |p0|stringrange| | |p1|stringrange| |

function Concatenate(p0 : StringRange, p1 : StringRange) : String

Contains : boolean

Returns if the string Contains the specified substring. |Name|Type|Description| |---|---|---| |p0|stringrange| |

function Contains(p0 : StringRange) : Boolean

EndsWith : boolean

Returns if the string ends with the specified substring. |Name|Type|Description| |---|---|---| |p0|stringrange| |

function EndsWith(p0 : StringRange) : Boolean

FindFirstOf : stringrange

Returns a StringRange that Contains the first occurrence of given StringRange. |Name|Type|Description| |---|---|---| |p0|stringrange| |

function FindFirstOf(p0 : StringRange) : StringRange

FindLastOf : stringrange

Returns a StringRange that Contains the last occurrence of given StringRange. |Name|Type|Description| |---|---|---| |p0|stringrange| |

function FindLastOf(p0 : StringRange) : StringRange

FindRangeExclusive : stringrange

Finds the first StringRange that starts with 'startRange' and ends with 'endRange'. This substring excludes 'startRange' and 'endRange'. |Name|Type|Description| |---|---|---| |startRange|stringrange| | |endRange|stringrange| |

function FindRangeExclusive(startRange : StringRange, endRange : StringRange) : StringRange

FindRangeInclusive : stringrange

Finds the first StringRange that starts with 'startRange' and ends with 'endRange'. This substring includes 'startRange' and 'endRange'. |Name|Type|Description| |---|---|---| |startRange|stringrange| | |endRange|stringrange| |

function FindRangeInclusive(startRange : StringRange, endRange : StringRange) : StringRange

FormatC : string

static

Name Type Description
format string
p1 T
function FormatC(format : String, p1 : T) : String

FormatC : string

static

Name Type Description
format string
p1 T
p2 T
function FormatC(format : String, p1 : T, p2 : T) : String

FormatC : string

static

Name Type Description
format string
p1 T
p2 T
p3 T
function FormatC(format : String, p1 : T, p2 : T, p3 : T) : String

FormatC : string

static

Name Type Description
format string
p1 T
p2 T
p3 T
p4 T
function FormatC(format : String, p1 : T, p2 : T, p3 : T, p4 : T) : String

FormatC : string

static

Name Type Description
format string
p1 T
p2 T
p3 T
p4 T
p5 T
function FormatC(format : String, p1 : T, p2 : T, p3 : T, p4 : T, p5 : T) : String

FormatC : string

static

Name Type Description
format string
p1 T
p2 T
p3 T
p4 T
p5 T
p6 T
function FormatC(format : String, p1 : T, p2 : T, p3 : T, p4 : T, p5 : T, p6 : T) : String

FormatC : string

static

Name Type Description
format string
p1 T
p2 T
p3 T
p4 T
p5 T
p6 T
p7 T
function FormatC(format : String, p1 : T, p2 : T, p3 : T, p4 : T, p5 : T, p6 : T, p7 : T) : String

FormatC : string

static

Name Type Description
format string
p1 T
p2 T
p3 T
p4 T
p5 T
p6 T
p7 T
p8 T
function FormatC(format : String, p1 : T, p2 : T, p3 : T, p4 : T, p5 : T, p6 : T, p7 : T, p8 : T) : String

FormatC : string

static

Name Type Description
format string
p1 T
p2 T
p3 T
p4 T
p5 T
p6 T
p7 T
p8 T
p9 T
function FormatC(format : String, p1 : T, p2 : T, p3 : T, p4 : T, p5 : T, p6 : T, p7 : T, p8 : T, p9 : T) : String

FormatC : string

static

Name Type Description
format string
p1 T
p2 T
p3 T
p4 T
p5 T
p6 T
p7 T
p8 T
p9 T
p10 T
function FormatC(format : String, p1 : T, p2 : T, p3 : T, p4 : T, p5 : T, p6 : T, p7 : T, p8 : T, p9 : T, p10 : T) : String

FromRune : string

static

Constructs a string from the utf-8 code point of a rune. |Name|Type|Description| |---|---|---| |p0|integer| |

function FromRune(p0 : Integer) : String

FromRune : string

static

Constructs a string from a rune. |Name|Type|Description| |---|---|---| |p0|rune| |

function FromRune(p0 : Rune) : String

Get : rune

String operator Get is deprecated. To iterate through a String use a StringRange (.All) or StringIterator (.Begin). |Name|Type|Description| |---|---|---| |index|integer| |

function Get(index : Integer) : Rune

IsNullOrEmpty : boolean

static

Returns if the given string is null or empty. |Name|Type|Description| |---|---|---| |p0|stringrange| |

function IsNullOrEmpty(p0 : StringRange) : Boolean

IsNullOrWhitespace : boolean

static

Returns if the given string is null, empty, or all whitespace. |Name|Type|Description| |---|---|---| |p0|stringrange| |

function IsNullOrWhitespace(p0 : StringRange) : Boolean

Join : string

static

Concatenates the given strings with the given separator string. |Name|Type|Description| |---|---|---| |separator|stringrange| | |value0|stringrange| | |value1|stringrange| |

function Join(separator : StringRange, value0 : StringRange, value1 : StringRange) : String

Join : string

static

Concatenates the given strings with the given separator string. |Name|Type|Description| |---|---|---| |separator|stringrange| | |value0|stringrange| | |value1|stringrange| | |value2|stringrange| |

function Join(separator : StringRange, value0 : StringRange, value1 : StringRange, value2 : StringRange) : String

Join : string

static

Concatenates the given strings with the given separator string. |Name|Type|Description| |---|---|---| |separator|stringrange| | |value0|stringrange| | |value1|stringrange| | |value2|stringrange| | |value3|stringrange| |

function Join(separator : StringRange, value0 : StringRange, value1 : StringRange, value2 : StringRange, value3 : StringRange) : String

Replace : string

Returns a new string with all occurances of a substrings replaced with another substring. |Name|Type|Description| |---|---|---| |oldValue|stringrange| | |newValue|stringrange| |

function Replace(oldValue : StringRange, newValue : StringRange) : String

RuneIteratorFromByteIndex : runeiterator

Finds the iterator from a byte index. WARNING: Strings are UTF8 and constructing an iterator from bytes indices can make an iterator in the middle of a rune. |Name|Type|Description| |---|---|---| |byteIndex|integer| |

function RuneIteratorFromByteIndex(byteIndex : Integer) : RuneIterator

RuneIteratorFromRuneIndex : runeiterator

Finds the iterator from a rune index. WARNING: this may be slow as finding an iterator from rune index requires a linear search. |Name|Type|Description| |---|---|---| |runeIndex|integer| |

function RuneIteratorFromRuneIndex(runeIndex : Integer) : RuneIterator

Split : stringsplitrange

Splits the string, according to the separator string, into a range of substrings. |Name|Type|Description| |---|---|---| |separator|stringrange| |

function Split(separator : StringRange) : StringSplitRange

StartsWith : boolean

Returns if the string starts with the specified substring. |Name|Type|Description| |---|---|---| |p0|stringrange| |

function StartsWith(p0 : StringRange) : Boolean

SubString : string

Name Type Description
start runeiterator
end runeiterator
function SubString(start : RuneIterator, end : RuneIterator) : String

SubStringBytes : stringrange

Constructs a substring based upon a number of bytes. WARNING: strings are UTF8 so indexing by bytes could produce unexpected results on non-ascii strings. |Name|Type|Description| |---|---|---| |startByteIndex|integer| | |lengthInBytes|integer| |

function SubStringBytes(startByteIndex : Integer, lengthInBytes : Integer) : StringRange

SubStringFromRuneIndices : string

Creates a substring from start and end indices. WARNING: this may be slow as finding an index for a UTF8 string requires a linear search. |Name|Type|Description| |---|---|---| |startIndex|integer| | |endIndex|integer| |

function SubStringFromRuneIndices(startIndex : Integer, endIndex : Integer) : String

ToLower : string

Returns a copy of the string that has been converted to lowercase. |Name|Type|Description| |---|---|---|

function ToLower() : String

ToUpper : string

Returns a copy of the string that has been converted to uppercase. |Name|Type|Description| |---|---|---|

function ToUpper() : String

Trim : stringrange

Trims all leading and trailing whitespace. |Name|Type|Description| |---|---|---|

function Trim() : StringRange

TrimEnd : stringrange

Trims all trailing whitespace. |Name|Type|Description| |---|---|---|

function TrimEnd() : StringRange

TrimStart : stringrange

Trims all leading whitespace. |Name|Type|Description| |---|---|---|

function TrimStart() : StringRange