Documentation
¶
Index ¶
- func SetupRouter(apiHandler *APIHandler) *chi.Mux
- type APIHandler
- func (a *APIHandler) HandleCreateBackupRepo(w http.ResponseWriter, r *http.Request)
- func (a *APIHandler) HandleDelete(w http.ResponseWriter, r *http.Request)
- func (a *APIHandler) HandleGetBackupRepoByName(w http.ResponseWriter, r *http.Request)
- func (a *APIHandler) HandleGetBackupRepos(w http.ResponseWriter, r *http.Request)
- func (a *APIHandler) HandleIndex(w http.ResponseWriter, r *http.Request)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SetupRouter ¶
func SetupRouter(apiHandler *APIHandler) *chi.Mux
Types ¶
type APIHandler ¶
type APIHandler struct { Dispatcher *backup.BackupDispatcher Db *database.Database RepositoryAdder backup.RepositoryAdder BackupRepoNameGetter database.BackupRepoNameGetter BackupReposGetter database.BackupReposGetter BackupRepoInserter database.BackupRepoInserter BackupRepoProcessor backuprepo.BackupRepoProcessor TemplatesDir string StaticDir string }
func NewAPIHandler ¶
func NewAPIHandler(dispatcher *backup.BackupDispatcher, db *database.Database, templatesDir string) *APIHandler
func (*APIHandler) HandleCreateBackupRepo ¶
func (a *APIHandler) HandleCreateBackupRepo(w http.ResponseWriter, r *http.Request)
func (*APIHandler) HandleDelete ¶
func (a *APIHandler) HandleDelete(w http.ResponseWriter, r *http.Request)
func (*APIHandler) HandleGetBackupRepoByName ¶
func (a *APIHandler) HandleGetBackupRepoByName(w http.ResponseWriter, r *http.Request)
func (*APIHandler) HandleGetBackupRepos ¶
func (a *APIHandler) HandleGetBackupRepos(w http.ResponseWriter, r *http.Request)
func (*APIHandler) HandleIndex ¶
func (a *APIHandler) HandleIndex(w http.ResponseWriter, r *http.Request)
Click to show internal directories.
Click to hide internal directories.