intellij-randomness / com.fwdekker.randomness.word / Dictionary

Dictionary

interface Dictionary

A collection of words that may become inaccessible at any moment in time.

Properties

words

abstract val words: Set<String>

The words in the dictionary.

Functions

isValid

open fun isValid(): Boolean

Returns true iff validate does not throw an exception.

validate

abstract fun validate(): Unit

Throws an InvalidDictionaryException iff this dictionary is currently invalid.

Inheritors

BundledDictionary

class BundledDictionary : Dictionary

A Dictionary of which the underlying file is a resource in the JAR.

UserDictionary

class UserDictionary : Dictionary

A Dictionary of which the underlying file is a regular file.