database

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2020 License: AGPL-3.0, AGPL-3.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Connect

func Connect() error

func Remove

func Remove(id uint64) error

func Synchronize

func Synchronize()

Types

type Track

type Track struct {
	ID             uint64    `db:"id" json:"id,omitempty"`
	DateCreated    time.Time `db:"date_created" json:"date_created,omitempty"`
	DateModified   time.Time `db:"date_modified" json:"date_modified,omitempty"`
	Publisher      string    `db:"publisher" json:"publisher,omitempty"`
	Genre          string    `db:"genre" json:"genre,omitempty"`
	Credit         string    `db:"credit" json:"credit,omitempty"`
	DisplayBPM     uint16    `db:"displaybpm" json:"displaybpm,omitempty"`
	Length         uint64    `db:"length" json:"length,omitempty"`
	Title          string    `db:"title" json:"title,omitempty"`
	TitleRomani    string    `db:"title_romani" json:"title_romani,omitempty"`
	Artists        string    `db:"artists" json:"artists,omitempty"`
	ArtistsRomani  *string   `db:"artists_romani,omitempty" json:"artists_romani,omitempty"`
	Subtitle       string    `db:"subtitle" json:"subtitle,omitempty"`
	SubtitleRomani *string   `db:"subtitle_romani,omitempty" json:"subtitle_romani,omitempty"`
}

func SelectID

func SelectID(id uint64) (*Track, error)

func SelectName

func SelectName(name string) ([]*Track, error)

func SelectRecent

func SelectRecent(limit int) ([]*Track, error)

func (*Track) Edit

func (t *Track) Edit(id uint64) error

func (*Track) New

func (t *Track) New() error

func (*Track) Update

func (t *Track) Update() error

Jump to

Keyboard shortcuts

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