store

package
v3.0.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Jan 11, 2019 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DBImageStore

type DBImageStore struct {
	DB *sql.DB
}

func (DBImageStore) Create

func (s DBImageStore) Create(image models.Image) (models.Image, error)

func (DBImageStore) Destroy

func (s DBImageStore) Destroy(image models.Image) error

func (DBImageStore) Get

func (s DBImageStore) Get(id int) (models.Image, error)

func (DBImageStore) List

func (s DBImageStore) List() ([]models.Image, error)

func (DBImageStore) MarkAsReady

func (s DBImageStore) MarkAsReady(image models.Image) (models.Image, error)

type DBInstanceStore

type DBInstanceStore struct {
	DB *sql.DB
}

func (DBInstanceStore) Create

func (s DBInstanceStore) Create(instance models.Instance) (models.Instance, error)

func (DBInstanceStore) Destroy

func (s DBInstanceStore) Destroy(instance models.Instance) error

func (DBInstanceStore) Get

func (s DBInstanceStore) Get(id int) (models.Instance, error)

func (DBInstanceStore) List

func (s DBInstanceStore) List() ([]models.Instance, error)

type ImageStore

type ImageStore interface {
	List() ([]models.Image, error)
	Create(models.Image) (models.Image, error)
	Get(id int) (models.Image, error)
	Destroy(image models.Image) error
	MarkAsReady(models.Image) (models.Image, error)
}

type InstanceStore

type InstanceStore interface {
	Create(models.Instance) (models.Instance, error)
	List() ([]models.Instance, error)
	Get(id int) (models.Instance, error)
	Destroy(instance models.Instance) error
}

Jump to

Keyboard shortcuts

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