This method splits the string by a delimiter and returns an array of parts.
Parameters | Description |
---|---|
delimiter | string separator |
Returns an array of string parts.
If the delimiter is not found in the string, the entire string will be returned. If the delimiter is an empty string, all whitespace characters will be used to split the string.
#include "UltraEngine.h"
using namespace UltraEngine;
int main(int argc, const char* argv[])
{
String s = "dog,cat,raccoon,fox,crow,snake,rabbit,deer";
vector<String> sarr = s.Split(",");
for (auto s : sarr)
{
Print(s);
}
return 0;
}