示例#1
0
        private static bool HasOnlyHebrewChars(string word)
        {
            if (word.Length < 1)
            {
                return(false);
            }
            if (int.TryParse(word, out _))
            {
                return(false);
            }

            var regex = new Regex(@"[" + HebrewConsonantData.ValidHebrewCharSet() + "]");
            var match = regex.Match(word ?? throw new ArgumentNullException(nameof(word)));

            return(match.Success);
        }
示例#2
0
 private static bool IsHebrewChar(char c) => HebrewConsonantData.ValidHebrewCharSet().Contains(c);