package main

import (
	"context"
	"jisho/internal/word"
)

// App struct
type App struct {
	ctx context.Context
	word.Provider
}

// NewApp creates a new App application struct
func NewApp(p word.Provider) *App {
	return &App{Provider: p}
}

// startup is called when the app starts. The context is saved
// so we can call the runtime methods
func (a *App) startup(ctx context.Context) {
	a.ctx = ctx
}