KGy SOFT

StringSegmentExtensions Class

KGy SOFT Core Libraries Help
Provides extension methods for the StringSegment type.
Inheritance Hierarchy

SystemObject
  KGySoft.CoreLibrariesStringSegmentExtensions

Namespace:  KGySoft.CoreLibraries
Assembly:  KGySoft.CoreLibraries (in KGySoft.CoreLibraries.dll) Version: 5.3.0
Syntax

public static class StringSegmentExtensions

The StringSegmentExtensions type exposes the following members.

Methods

  NameDescription
Public methodStatic memberRead
Advances the specified rest parameter consuming up to maxLength characters and returns the consumed part. If rest started with a new line before the call, then an empty segment is returned. If the whole StringSegment has been processed, then rest will be StringSegment.Null after returning.
Public methodStatic memberReadLine
Advances the specified rest parameter after the current line and returns the consumed part without the newline character(s). If rest started with a new line before the call, then an empty segment is returned. If the whole StringSegment has been processed, then rest will be StringSegment.Null after returning.
Public methodStatic memberReadToSeparator(StringSegment, StringSegment)
Advances the specified rest parameter after the next separator and returns the consumed part without the separator. If rest started with separator before the call, then an empty segment is returned. If the whole StringSegment has been processed, then rest will be StringSegment.Null after returning.
Public methodStatic memberReadToSeparator(StringSegment, StringSegment)
Advances the specified rest parameter after the next separator and returns the consumed part without the separator. If rest started with one of the separators before the call, then an empty segment is returned. If the whole StringSegment has been processed, then rest will be StringSegment.Null after returning.
Public methodStatic memberReadToSeparator(StringSegment, Char)
Advances the specified rest parameter after the next separator character and returns the consumed part without the separator. If the first character of rest was a separator before the call, then an empty segment is returned. If the whole StringSegment has been processed, then rest will be StringSegment.Null after returning.
Public methodStatic memberReadToSeparator(StringSegment, Char)
Advances the specified rest parameter after the next separator and returns the consumed part without the separator. If rest started with one of the separators before the call, then an empty segment is returned. If the whole StringSegment has been processed, then rest will be StringSegment.Null after returning.
Public methodStatic memberReadToSeparator(StringSegment, ReadOnlySpanChar)
Advances the specified rest parameter after the next separator and returns the consumed part without the separator. If rest started with separator before the call, then an empty segment is returned. If the whole StringSegment has been processed, then rest will be StringSegment.Null after returning.
Public methodStatic memberReadToSeparator(StringSegment, String)
Advances the specified rest parameter after the next separator and returns the consumed part without the separator. If rest started with separator before the call, then an empty segment is returned. If the whole StringSegment has been processed, then rest will be StringSegment.Null after returning.
Public methodStatic memberReadToSeparator(StringSegment, String)
Advances the specified rest parameter after the next separator and returns the consumed part without the separator. If rest started with one of the separators before the call, then an empty segment is returned. If the whole StringSegment has been processed, then rest will be StringSegment.Null after returning.
Public methodStatic memberReadToWhiteSpace
Advances the specified rest parameter after the next whitespace character and returns the consumed part without the whitespace. If the first character of rest was a whitespace before the call, then an empty segment is returned. If the whole StringSegment has been processed, then rest will be StringSegment.Null after returning.
Public methodStatic memberRemoveQuotes
Extracts content of a single or double quoted string.
Public methodStatic memberToEnumTEnum
Tries to convert the specified StringSegment to an Enum value of TEnum type. No string allocation occurs when using this method.
Top
See Also

Reference