internal DoubleMetaphoneResult(int maxLength, DoubleMetaphone owner)
        {
            this.maxLength = maxLength;
            this.owner     = owner;

            primary   = new StringBuilder(owner.GetMaxCodeLen());
            alternate = new StringBuilder(owner.GetMaxCodeLen());
        }
        private bool AddWordInternal(string word)
        {
            if (!this.ContainsWord(word))
            {
                DoubleMetaphone metaphone    = new DoubleMetaphone();
                string          primaryKey   = metaphone.Encode(word, false);
                string          alternateKey = metaphone.Encode(word, true);

                this.WordsList.Add(word);
                this.AddWordToMetaphoneDictionaries(word, primaryKey, alternateKey);

                return(true);
            }
            return(false);
        }
        private bool AddWordInternal(string word)
        {
            if (!this.ContainsWord(word))
            {
                DoubleMetaphone metaphone = new DoubleMetaphone();
                string primaryKey = metaphone.Encode(word, false);
                string alternateKey = metaphone.Encode(word, true);

                this.WordsList.Add(word);
                this.AddWordToMetaphoneDictionaries(word, primaryKey, alternateKey);

                return true;
            }
            return false;
        }