AudioAsset
Ease
FastString
FontAsset
NineSlice
PackedSprite
PackedSpriteID
RB
   HardwareSettings
   IRetroBlitGame
RBAsset
Rect2i
ShaderAsset
SoundReference
SpriteGrid
SpriteSheetAsset
TMXMapAsset
   TMXLayer
   TMXLayerLoadState
   TMXObject
   TMXObjectGroup
   TMXProperties
Vector2i

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

FILL_SPACES Fill leading number spaces with spaces
FILL_ZEROS Fill leading number spaces with zeros
FORMAT_HEX_CAPS Format hex numbers with upper-case alpha characters
FORMAT_HEX_SMALL Format hex numbers with lower-case alpha characters
PRECISION_UNDEFINED Undefined float precision specifier

Properties

Buf The char buffer of the string
Capacity Capacity of string
Length Length of string
this[int index] Get character at given index.

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

operator!= Inequality operator
operator== Equality operator