Interface: IDictionaryRepository
Defined in: Data/Repositories/IDictionaryRepository.ts:10
Interface for Dictionary repository Defines all operations for working with dictionary/lexicon databases
Methods
browseByLetter()
browseByLetter(
letter,limit,offset):object
Defined in: Data/Repositories/IDictionaryRepository.ts:52
Parameters
letter
string | null
limit
number
offset
number
Returns
object
entries
entries:
object[]
total
total:
number
createEntry()
createEntry(
entry):DictionaryEntry
Defined in: Data/Repositories/IDictionaryRepository.ts:23
Parameters
entry
Returns
deleteEntry()
deleteEntry(
entryId):boolean
Defined in: Data/Repositories/IDictionaryRepository.ts:25
Parameters
entryId
number
Returns
boolean
getAdjacentEntries()
getAdjacentEntries(
entryKey):object
Defined in: Data/Repositories/IDictionaryRepository.ts:53
Parameters
entryKey
string
Returns
object
next
next: {
entryKey:string;word:string; } |null
prev
prev: {
entryKey:string;word:string; } |null
getAllEntries()
getAllEntries(
options?):DictionaryEntry[]
Defined in: Data/Repositories/IDictionaryRepository.ts:18
Parameters
options?
limit?
number
offset?
number
Returns
getEntriesReferencingVerse()
getEntriesReferencingVerse(
verseId):DictionaryEntry[]
Defined in: Data/Repositories/IDictionaryRepository.ts:42
Entries citing a given verse. Only answerable on a v2 module — on v1 the citations live in an unindexed JSON column, so this returns empty there.
Parameters
verseId
number
Returns
getEntry()
getEntry(
entryId):DictionaryEntry|undefined
Defined in: Data/Repositories/IDictionaryRepository.ts:16
Parameters
entryId
number
Returns
DictionaryEntry | undefined
getEntryByKey()
getEntryByKey(
entryKey):DictionaryEntry|undefined
Defined in: Data/Repositories/IDictionaryRepository.ts:17
Parameters
entryKey
string
Returns
DictionaryEntry | undefined
getEntryCount()
getEntryCount():
number
Defined in: Data/Repositories/IDictionaryRepository.ts:54
Returns
number
getExampleVerses()
getExampleVerses(
entryId):ExampleVerse[]
Defined in: Data/Repositories/IDictionaryRepository.ts:33
Example verses cited by an entry. Reads the unified verse_link table
(source_type='dictionary_entry') on a v2 module and the legacy JSON
example_verses column on a v1 module.
Parameters
entryId
number
Returns
getLetterIndex()
getLetterIndex():
object[]
Defined in: Data/Repositories/IDictionaryRepository.ts:49
Returns
object[]
getModuleInfo()
getModuleInfo():
DictionaryModuleInfo|undefined
Defined in: Data/Repositories/IDictionaryRepository.ts:12
Returns
DictionaryModuleInfo | undefined
getOccurrences()
getOccurrences(
entryKey):WordOccurrence[]
Defined in: Data/Repositories/IDictionaryRepository.ts:45
Parameters
entryKey
string
Returns
getOccurrencesForVerse()
getOccurrencesForVerse(
verseId):WordOccurrence[]
Defined in: Data/Repositories/IDictionaryRepository.ts:46
Parameters
verseId
number
Returns
getVerseLinksForEntry()
getVerseLinksForEntry(
entryId):VerseLinkRecord[]
Defined in: Data/Repositories/IDictionaryRepository.ts:36
An entry's verse links in the unified v2 shape. Empty on a v1 module.
Parameters
entryId
number
Returns
searchByTitle()
searchByTitle(
query,options?):DictionaryEntry[]
Defined in: Data/Repositories/IDictionaryRepository.ts:20
Parameters
query
string
options?
limit?
number
Returns
searchEntries()
searchEntries(
query,options?):DictionaryEntry[]
Defined in: Data/Repositories/IDictionaryRepository.ts:19
Parameters
query
string
options?
limit?
number
Returns
updateEntry()
updateEntry(
entry):DictionaryEntry
Defined in: Data/Repositories/IDictionaryRepository.ts:24
Parameters
entry
Returns
updateModuleInfo()
updateModuleInfo(
info):void
Defined in: Data/Repositories/IDictionaryRepository.ts:13
Parameters
info
Returns
void