internal static SortedList <int, IReadOnlyList <ITile> > CreateSuggestionLists(WordVocabularySource source,
                                                                                       StringTokens tokens,
                                                                                       TokenPredictor tokenPredictor,
                                                                                       int[] context,
                                                                                       ITokenTileFilter filter,
                                                                                       bool isFirstWord,
                                                                                       int lowerBound,
                                                                                       int upperBound,
                                                                                       int maxListCount,
                                                                                       int maxListItemCount)
        {
            BreakOnProblemCase(tokens, context, "these", "are", "the", "voyages");

            var maker = tokenPredictor.CreatePredictionMaker(source, filter.IsTokenVisible, context);

            var creator = new SuggestedWordListsCreator(source, tokens, maker, filter.IsTokenVisible, isFirstWord, lowerBound, upperBound, maxListCount, maxListItemCount);
            var list    = creator.Run();

            return(list);
        }
Пример #2
0
        internal TokenPredictor CreateEmpty()
        {
            var predictor = new TokenPredictor(_width);

            return(predictor);
        }
Пример #3
0
 internal void Add(TokenPredictor predictor)
 {
     AddTokens(_database, predictor._database);
 }
Пример #4
0
 internal void Subtract(TokenPredictor predictor)
 {
     SubtractTokens(_database, predictor._database);
 }