using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace RomCheater.UserSettingsSupport { internal static class StringUtil { // Parts from System.Configuration.StringUtil internal static bool StringStartsWithIgnoreCase(string s1, string s2) { if (string.IsNullOrEmpty(s1) || string.IsNullOrEmpty(s2)) { return false; } if (s2.Length > s1.Length) { return false; } return (0 == string.Compare(s1, 0, s2, 0, s2.Length, StringComparison.OrdinalIgnoreCase)); } internal static bool StartsWithIgnoreCase(string s1, string s2) { if (s2 == null) { return false; } return (0 == string.Compare(s1, 0, s2, 0, s2.Length, StringComparison.OrdinalIgnoreCase)); } } }