autostart

package
v0.0.0-...-d23ef4a Latest Latest
Warning

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

Go to latest
Published: Jun 20, 2018 License: MIT Imports: 10 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Repository

type Repository interface {
	io.Closer
	InsertAutoStart(autoStart *models.AutoStart) error
	FindAutoStartByID(id int64) (models.AutoStart, error)
	FindAll() ([]models.AutoStart, error)
	DeleteAutoStartByID(id int64) (models.AutoStart, error)
	DeleteAll() error
	UpdateAutoStartByID(id int64, fields map[string]interface{}) (models.AutoStart, error)
}

Repository handles the basic operations of a AutoStart entity/model. It's an interface in order to be testable, i.e a memory AutoStart repository or a connected to an sql database.

func NewAutostartRepository

func NewAutostartRepository() Repository

NewAutostartRepository returns a new AutoStart memory-based repository, the one and only repository type in our example.

Jump to

Keyboard shortcuts

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