FastString
Class
Description
A class for handling strings without the costs of garbage collection. Using C# string type can have a significant impact on the garbage collector because most string manipulation operations cause reallocation of the underlying string buffer. FastString works exclusively with a single pre-allocated buffer and will not cause any unexpected garbage collection.
All RetroBlit methods that take in a string parameter also have a FastString overload that can be used instead.
Constants
Properties
Methods
Append
(21 overloads)
|
Append a value to the string
|
Clear
|
Clear the string
|
Contains
(3 overloads)
|
Returns true if contains given string
|
EndsWith
(2 overloads)
|
Returns true if string ends with the given string
|
Equals
|
FastString
equality
|
Equals
|
String equality
|
FastString
|
Constructor
|
GetHashCode
|
Get string hashcode
|
IndexOf
(3 overloads)
|
Return first index of given string
|
LastIndexOf
(6 overloads)
|
Return last index of given string
|
PadLeft
|
Pad string with paddingChar on the left side
|
PadRight
|
Pad string with paddingChar on the right side
|
Remove
(2 overloads)
|
Remove a section of the string
|
Replace
(5 overloads)
|
Replace all instances of the given string with a new string.
|
Set
(21 overloads)
|
Clear the string and set it to a new value.
|
StartsWith
(2 overloads)
|
Returns true if string starts with the given string
|
Substring
(2 overloads)
|
Set to a substring of the original string
|
ToLower
|
Convert to lower case characters.
|
ToLowerInvariant
|
Convert to lower case characters. The results will be consistent regardless of regional settings.
|
ToString
|
Convert to string
|
ToUpper
|
Convert to upper case characters.
|
ToUpperInvariant
|
Convert to upper case characters. The results will be consistent regardless of regional settings.
|
Trim
|
Trim all leading and trailing spaces from the string
|
TrimEnd
|
Trim all trailing spaces from the string
|
TrimStart
|
Trim all leading spaces from the string
|
Truncate
|
Truncate the string to the given length
|
Operators
|