SplitEnumerator Method
- Namespace
- SatorImaging.UnityFundamentals
SplitEnumerator(ReadOnlySpan<char>, char)
public static NonAllocIncrementalStringSplitter SplitEnumerator(this ReadOnlySpan<char> text, char splitter)
Non-alloc, incremental string splitter designed for use with foreach statement. This enumerator searches text only when requested so good to use with larger text.
Parameters
textReadOnlySpan<char>splitterchar
Returns
- NonAllocIncrementalStringSplitter
Rangeenumerator
SplitEnumerator(string, char)
public static NonAllocIncrementalStringSplitter SplitEnumerator(this string text, char splitter)
Non-alloc, incremental string splitter designed for use with foreach statement. This enumerator searches text only when requested so good to use with larger text.
Parameters
Returns
- NonAllocIncrementalStringSplitter
Rangeenumerator
SplitEnumerator(ReadOnlySpan<char>, ReadOnlySpan<char>, bool)
public static NonAllocIncrementalStringSplitter SplitEnumerator(this ReadOnlySpan<char> text, ReadOnlySpan<char> sequence, bool splitByAnyChar)
Non-alloc, incremental string splitter designed for use with foreach statement. This enumerator searches text only when requested so good to use with larger text.
Parameters
textReadOnlySpan<char>sequenceReadOnlySpan<char>splitByAnyCharbool
Returns
- NonAllocIncrementalStringSplitter
Rangeenumerator
SplitEnumerator(string, ReadOnlySpan<char>, bool)
public static NonAllocIncrementalStringSplitter SplitEnumerator(this string text, ReadOnlySpan<char> sequence, bool splitByAnyChar)
Non-alloc, incremental string splitter designed for use with foreach statement. This enumerator searches text only when requested so good to use with larger text.
Parameters
textstringsequenceReadOnlySpan<char>splitByAnyCharbool
Returns
- NonAllocIncrementalStringSplitter
Rangeenumerator