Esempio n. 1
0
 public static bool IsWhiteSpace(string s, int index)
 {
     if (s == null)
     {
         throw new ArgumentNullException("s");
     }
     if (index >= s.Length)
     {
         throw new ArgumentOutOfRangeException("index");
     }
     if (IsLatin1(s[index]))
     {
         return(IsWhiteSpaceLatin1(s[index]));
     }
     return(CharUnicodeInfo.IsWhiteSpace(s, index));
 }
Esempio n. 2
0
        public static bool IsWhiteSpace(String s, int index)
        {
            if (s == null)
            {
                throw new ArgumentNullException(nameof(s));
            }
            if (((uint)index) >= ((uint)s.Length))
            {
                throw new ArgumentOutOfRangeException(nameof(index));
            }

            if (IsLatin1(s[index]))
            {
                return(IsWhiteSpaceLatin1(s[index]));
            }

            return(CharUnicodeInfo.IsWhiteSpace(s, index));
        }