Skip to main content

Interface: SpellingDictionaryCollection

Defined in: packages/cspell-dictionary/dist/SpellingDictionary/SpellingDictionaryCollection.d.ts:2

Extends

Properties

containsNoSuggestWords

readonly containsNoSuggestWords: boolean

Defined in: packages/cspell-dictionary/dist/SpellingDictionary/SpellingDictionary.d.ts:91

Inherited from

SpellingDictionary.containsNoSuggestWords


dictionaries

readonly dictionaries: SpellingDictionary[]

Defined in: packages/cspell-dictionary/dist/SpellingDictionary/SpellingDictionaryCollection.d.ts:4


getPreferredSuggestions()?

optional getPreferredSuggestions: (word) => PreferredSuggestion[]

Defined in: packages/cspell-dictionary/dist/SpellingDictionary/SpellingDictionary.d.ts:114

Parameters

word

string

Returns

PreferredSuggestion[]

Inherited from

SpellingDictionary.getPreferredSuggestions


isDictionaryCaseSensitive

readonly isDictionaryCaseSensitive: boolean

Defined in: packages/cspell-dictionary/dist/SpellingDictionary/SpellingDictionary.d.ts:125

Inherited from

SpellingDictionary.isDictionaryCaseSensitive


name

readonly name: string

Defined in: packages/cspell-dictionary/dist/SpellingDictionary/SpellingDictionary.d.ts:83

The name of the dictionary

Inherited from

SpellingDictionary.name


options

readonly options: SpellingDictionaryOptions

Defined in: packages/cspell-dictionary/dist/SpellingDictionary/SpellingDictionary.d.ts:87

Options

Inherited from

SpellingDictionary.options


remapWord()?

optional remapWord: (word) => string[]

Defined in: packages/cspell-dictionary/dist/SpellingDictionary/SpellingDictionary.d.ts:123

Generates all possible word combinations by applying repMap. This acts a bit like brace expansions in globs.

Parameters

word

string

the word to map

Returns

string[]

array of adjusted words.

Inherited from

SpellingDictionary.remapWord


size

readonly size: number

Defined in: packages/cspell-dictionary/dist/SpellingDictionary/SpellingDictionary.d.ts:124

Inherited from

SpellingDictionary.size


source

readonly source: string

Defined in: packages/cspell-dictionary/dist/SpellingDictionary/SpellingDictionary.d.ts:85

The source, filename or URI

Inherited from

SpellingDictionary.source


type

readonly type: "SpellingDictionaryCollection"

Defined in: packages/cspell-dictionary/dist/SpellingDictionary/SpellingDictionaryCollection.d.ts:3

Overrides

SpellingDictionary.type

Methods

find()

find(word, options?): undefined | FindResult

Defined in: packages/cspell-dictionary/dist/SpellingDictionary/SpellingDictionary.d.ts:94

A more detailed search for a word, might take longer than has

Parameters

word

string

options?

Readonly<SearchOptions>

Returns

undefined | FindResult

Inherited from

SpellingDictionary.find


genSuggestions()

genSuggestions(collector, suggestOptions): void

Defined in: packages/cspell-dictionary/dist/SpellingDictionary/SpellingDictionary.d.ts:115

Parameters

collector

SuggestionCollector

suggestOptions

Readonly

Returns

void

Inherited from

SpellingDictionary.genSuggestions


getErrors()

getErrors(): Error[]

Defined in: packages/cspell-dictionary/dist/SpellingDictionary/SpellingDictionaryCollection.d.ts:5

Returns

Error[]

Overrides

SpellingDictionary.getErrors


has()

has(word, options?): boolean

Defined in: packages/cspell-dictionary/dist/SpellingDictionary/SpellingDictionary.d.ts:92

Parameters

word

string

options?

Readonly<SearchOptions>

Returns

boolean

Inherited from

SpellingDictionary.has


isForbidden()

isForbidden(word, ignoreCaseAndAccents?): boolean

Defined in: packages/cspell-dictionary/dist/SpellingDictionary/SpellingDictionary.d.ts:99

Checks if a word is forbidden.

Parameters

word

string

word to check.

ignoreCaseAndAccents?

boolean

Returns

boolean

Inherited from

SpellingDictionary.isForbidden


isNoSuggestWord()

isNoSuggestWord(word, options): boolean

Defined in: packages/cspell-dictionary/dist/SpellingDictionary/SpellingDictionary.d.ts:107

No Suggest words are considered correct but will not be listed when suggestions are generated. No Suggest words and "Ignored" words are equivalent. Ignored / no suggest words override forbidden words.

Parameters

word

string

word to check

options

Readonly

options

Returns

boolean

Inherited from

SpellingDictionary.isNoSuggestWord


mapWord()

mapWord(word): string

Defined in: packages/cspell-dictionary/dist/SpellingDictionary/SpellingDictionary.d.ts:116

Parameters

word

string

Returns

string

Inherited from

SpellingDictionary.mapWord


suggest()

suggest(word, suggestOptions?): SuggestionResult[]

Defined in: packages/cspell-dictionary/dist/SpellingDictionary/SpellingDictionary.d.ts:113

Generate suggestions for a word

Parameters

word

string

word

suggestOptions?

Readonly<SuggestOptions>

options

Returns

SuggestionResult[]

Inherited from

SpellingDictionary.suggest