IsCompatibleWith() public method

Determines if the current encoded word has the same encoding name and encoding type
public IsCompatibleWith ( EncodedWord other ) : bool
other EncodedWord
return bool
Example #1
0
        /// <summary>
        /// Determines if the next token in the list (if any) match the encoded word regular expression and has the same encoding and charset values
        /// </summary>
        private bool NextTokenIsCompatible(EncodedWord encodedWord, int currentIndex)
        {
            if (currentIndex + 1 >= _encodedWords.Count)
            {
                return(false);
            }

            var nextEncodedWord = _encodedWords[currentIndex + 1];

            return(encodedWord.IsCompatibleWith(nextEncodedWord));
        }
Example #2
0
        /// <summary>
        /// Determines if the next token in the list (if any) match the encoded word regular expression and has the same encoding and charset values
        /// </summary>
        private bool NextTokenIsCompatible(EncodedWord encodedWord, int currentIndex)
        {
            if (currentIndex + 1 >= _encodedWords.Count)
            {
                return false;
            }

            var nextEncodedWord = _encodedWords[currentIndex + 1];
            return encodedWord.IsCompatibleWith(nextEncodedWord);
        }