Example #1
0
 /// <summary>
 /// Returns a string array that contains the substrings in this string that are delimited by elements of a specified Unicode character array. A parameter specifies whether to return empty array elements.
 /// </summary>
 /// <param name="separator"></param>
 /// <param name="options"></param>
 /// <returns></returns>
 public static IEnumerable <string> SplitString(this string text, char[] separator, StringSplitOptions options)
 {
     return(StringSplitter.DoSplitString(text, separator, int.MaxValue, options));
 }
Example #2
0
 /// <summary>
 /// Returns a string array that contains the substrings in this string that are delimited by elements of a specified string array. Parameters specify the maximum number of substrings to return and whether to return empty array elements.
 /// </summary>
 /// <param name="separator"></param>
 /// <param name="count"></param>
 /// <param name="options"></param>
 /// <returns></returns>
 public static IEnumerable <string> SplitString(this string text, string[] separator, int count, StringSplitOptions options)
 {
     return(StringSplitter.DoSplitString(text, separator, count, options));
 }
Example #3
0
 /// <summary>
 ///Returns a string array that contains the substrings in this instance that are delimited by elements of a specified Unicode character array. A parameter specifies the maximum number of substrings to return.
 /// </summary>
 /// <param name="separator"></param>
 /// <param name="count"></param>
 /// <returns></returns>
 public static IEnumerable <string> SplitString(this string text, char[] separator, int count)
 {
     return(StringSplitter.DoSplitString(text, separator, count, StringSplitOptions.None));
 }