StringSegmentSplit(String, NullableInt32, StringSegmentSplitOptions) Method
Namespace: KGySoft.CoreLibrariesAssembly: KGySoft.CoreLibraries (in KGySoft.CoreLibraries.dll) Version: 10.0.0
public IList<StringSegment> Split(
string?[]? separators,
int? maxLength,
StringSegmentSplitOptions options = default
)
Public Function Split (
separators As String(),
maxLength As Integer?,
Optional options As StringSegmentSplitOptions = Nothing
) As IList(Of StringSegment)
public:
IList<StringSegment>^ Split(
array<String^>^ separators,
Nullable<int> maxLength,
StringSegmentSplitOptions options = StringSegmentSplitOptions()
)
member Split :
separators : string[] *
maxLength : Nullable<int> *
?options : StringSegmentSplitOptions
(* Defaults:
let _options = defaultArg options new StringSegmentSplitOptions()
*)
-> IList<StringSegment>
- separators String
- An array of strings that delimits the segments in this StringSegment. If or contains no elements,
then the split operation will use whitespace separators. If contains only or empty elements, then no splitting will occur.
- maxLength NullableInt32
- The maximum number of segments to return. If , then the whole string is processed represented by this StringSegment. This parameter is optional.
Default value: . - options StringSegmentSplitOptions (Optional)
- A StringSegmentSplitOptions value that specifies whether to trim segments and remove empty entries. This parameter is optional.
Default value: None.
IListStringSegmentA list of
StringSegment instances, whose elements contain the substrings in this
StringSegment that are
delimited by
separators.