@@ -181,7 +181,7 @@ internal static CompareInfo CreateComparer()
181
181
/// <param name="oldValue">Value to replace</param>
182
182
/// <param name="newValue">value to replace with</param>
183
183
/// <returns>String with all multiple occurrences replaced</returns>
184
- internal static string ReplaceRecursive ( string original , string oldValue , string newValue )
184
+ private static string ReplaceRecursive ( string original , string oldValue , string newValue )
185
185
{
186
186
const int maxTries = 1000 ;
187
187
@@ -244,19 +244,7 @@ internal static string ToValidIdentifier(string original)
244
244
/// <returns>string with values replaced</returns>
245
245
public static string ReplaceIgnoringCase ( string original , string oldValue , string newValue )
246
246
{
247
- return Replace ( original , oldValue , newValue , StringComparison . OrdinalIgnoreCase ) ;
248
- }
249
-
250
- /// <summary>
251
- /// String replace with a comparison function, eg OridinalIgnoreCase
252
- /// </summary>
253
- /// <param name="original">Original string</param>
254
- /// <param name="oldValue">Value to be replaced</param>
255
- /// <param name="newValue">value to replace with</param>
256
- /// <param name="comparisionType">Comparison type (enum)</param>
257
- /// <returns>String with values replaced</returns>
258
- public static string Replace ( string original , string oldValue , string newValue , StringComparison comparisionType )
259
- {
247
+ StringComparison comparisionType = StringComparison . OrdinalIgnoreCase ;
260
248
string result = original ;
261
249
262
250
if ( ! string . IsNullOrEmpty ( oldValue ) )
@@ -281,27 +269,6 @@ public static string Replace(string original, string oldValue, string newValue,
281
269
return result ;
282
270
}
283
271
284
- /// <summary>
285
- /// Indicates whether a specified string is null, empty, or consists only of white-space characters.
286
- /// </summary>
287
- /// <param name="value">The string to test.</param>
288
- /// <returns>true if the parameter is null, empty, or consists only of white-space characters.</returns>
289
- public static bool IsNullOrWhiteSpace ( string value )
290
- {
291
- if ( value == null )
292
- {
293
- return true ;
294
- }
295
- for ( int i = 0 ; i < value . Length ; i ++ )
296
- {
297
- if ( ! char . IsWhiteSpace ( value [ i ] ) )
298
- {
299
- return false ;
300
- }
301
- }
302
- return true ;
303
- }
304
-
305
272
/// <summary>
306
273
/// Determines whether the beginning of this string instance matches the specified string ignoring white spaces at the start.
307
274
/// </summary>
0 commit comments