StringSegmentIndexOf(ReadOnlySpanChar, StringComparison) Method
Gets the zero-based index of the first occurrence of the specified
value in this
StringSegment
using the specified
comparison.
Namespace: KGySoft.CoreLibrariesAssembly: KGySoft.CoreLibraries (in KGySoft.CoreLibraries.dll) Version: 10.0.0
public int IndexOf(
ReadOnlySpan<char> value,
StringComparison comparison
)
Public Function IndexOf (
value As ReadOnlySpan(Of Char),
comparison As StringComparison
) As Integer
public:
int IndexOf(
ReadOnlySpan<wchar_t> value,
StringComparison comparison
)
member IndexOf :
value : ReadOnlySpan<char> *
comparison : StringComparison -> int
- value ReadOnlySpanChar
- The ReadOnlySpan<char> to seek.
- comparison StringComparison
- A StringComparison value that specified the rules for the search.
Int32The zero-based index position of
value if that
ReadOnlySpan<char> is found, or -1 if it is not.
If value is
ReadOnlySpan<char>.Empty, the return value is 0.