db

package
v0.1.0-beta.10 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 25, 2020 License: Apache-2.0 Imports: 15 Imported by: 20

Documentation

Index

Constants

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	DbDir      string
	ListingURL string
}

type Curator

type Curator struct {
	// contains filtered or unexported fields
}

func NewCurator

func NewCurator(cfg Config) Curator

func (*Curator) Delete

func (c *Curator) Delete() error

func (*Curator) GetStore

func (c *Curator) GetStore() (v1.StoreReader, error)

func (*Curator) ImportFrom

func (c *Curator) ImportFrom(dbArchivePath string) error

func (*Curator) IsUpdateAvailable

func (c *Curator) IsUpdateAvailable() (bool, *curation.ListingEntry, error)

func (*Curator) Status

func (c *Curator) Status() Status

func (*Curator) Update

func (c *Curator) Update() (bool, error)

func (*Curator) UpdateTo

func (c *Curator) UpdateTo(listing *curation.ListingEntry, downloadProgress, importProgress *progress.Manual, stage *progress.Stage) error

func (*Curator) Validate

func (c *Curator) Validate() error

Validate checks the current database to ensure file integrity and if it can be used by this version of the application.

type Status

type Status struct {
	Age                   time.Time
	CurrentSchemaVersion  int
	RequiredSchemaVersion int
	Location              string
	Err                   error
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL