Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( DbaseDir string // dictionary database directory. DictDbase map[string]DictEntity // dictionary database. DictWords []string // sorted list of dictionary words )
Functions ¶
func FetchDbase ¶
func FetchDbase() (err error)
FetchDbase downloads dictionary database files contained in the **remoteFiles** variable. The user's local database files changes tracker is updated to ensure that no download is made on database files without any changes.
func RenderLayout ¶
func RenderLayout()
RenderLayout renders dictionary terminal user interface layout.
func UpdateDbase ¶
func UpdateDbase() (err error)
UpdateDbase attempts to try and update user's local dictionary database, by first checking for database files that have changed on the remote repository and then download those files if any.
Types ¶
type Definition ¶
type DictEntity ¶
type DictEntity struct { Word string `json:"word"` Spellings []string `json:"alternate_spellings,omitempty"` WordDefinitions []Definition `json:"definitions"` }
DictEntity represents the structure of elements/entities in the dictionary database.
Click to show internal directories.
Click to hide internal directories.