예제 #1
0
 public LameBoard(BoardProperties.BoardStyle style, IBoggleDictionary dictionary, string letters) : base(style, dictionary, letters)
 {
 }
예제 #2
0
        private static IBoard GetBoard(BoardProperties.BoardType board, IBoggleDictionary dictionary, BoardProperties.BoardStyle style, string letters)
        {
            string boardName = Enum.GetName(typeof(BoardProperties.BoardType), board);

            letters = letters.ToLower();

            switch (boardName.ToLower())
            {
            case Constants.LAME_BOARDTYPE:
                return(new LameBoard(style, dictionary, letters));

            case Constants.TRIE_BOARDTYPE:
                return(new TrieBoard(style, dictionary, letters));

            default:
                return(new LameBoard(style, dictionary, letters));    //default to lame board for testing
            }
        }
예제 #3
0
        public static IBoard CreateBoard(BoardProperties.BoardStyle style, BoardProperties.DictionaryType dictionary, BoardProperties.BoardType board, string letters)
        {
            IBoggleDictionary boardDictionary = GetBoggleDictionary(dictionary);

            return(GetBoard(board, boardDictionary, style, letters));
        }
예제 #4
0
 public BaseBoard(BoardProperties.BoardStyle style, IBoggleDictionary dictionary, string letters)
 {
     Style      = style;
     Dictionary = dictionary;
     Letters    = letters;
 }