예제 #1
0
 private static bool CheckValidWord(WordBuilder builder)
 {
     StringBuilder searchString = new StringBuilder(builder.CurrentString.Length);
     StringBuilder reverseSearchString = new StringBuilder(builder.CurrentString.Length);
     searchString.Copy(builder.CurrentString);
     reverseSearchString.Copy(builder.CurrentReversedString);
     searchString.Decorate();
     reverseSearchString.Decorate();
     if (Shorewood.wordDatabase.Search(searchString) || Shorewood.wordDatabase.Search(reverseSearchString))
     {
         wordAvailable = true;
         return true;
     }
     return false;
 }