All Downloads are FREE. Search and download functionalities are using the official Maven repository.

commonMain.com.darkrockstudios.symspellkt.api.DictionaryHolder.kt Maven / Gradle / Ivy

Go to download

A Kotlin Multiplatform implementation of the SymSpell Spell Checking algorithm.

There is a newer version: 3.1.0
Show newest version
package com.darkrockstudios.symspellkt.api

import com.darkrockstudios.symspellkt.common.DictionaryItem
import com.darkrockstudios.symspellkt.exception.SpellCheckException

/**
 * Interface to contain the dictionary
 */
interface DictionaryHolder {
	@Throws(SpellCheckException::class)
	fun addItem(dictionaryItem: DictionaryItem): Boolean

	@Throws(SpellCheckException::class)
	fun getItemFrequency(term: String): Double?

	@Throws(SpellCheckException::class)
	fun getItemFrequencyBiGram(term: String): Double?

	@Throws(SpellCheckException::class)
	fun getDeletes(key: String): ArrayList?

	val wordCount: Int

	@Throws(SpellCheckException::class)
	fun clear(): Boolean

	fun addExclusionItem(key: String, value: String)

	fun addExclusionItems(values: Map)

	fun getExclusionItem(key: String): String?
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy