data

package
v0.0.0-...-92f9948 Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2016 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewDatabaseConnection

func NewDatabaseConnection(rootPath string) (database *db.DB)

Types

type GenericModel

type GenericModel map[string]interface{}

type GenericRepository

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

func NewGenericRepository

func NewGenericRepository(database *db.DB, coll string) *GenericRepository

func (*GenericRepository) Delete

func (repo *GenericRepository) Delete(id int)

func (*GenericRepository) Fetch

func (repo *GenericRepository) Fetch(id int) GenericModel

func (*GenericRepository) FetchAll

func (repo *GenericRepository) FetchAll() []GenericModel

func (*GenericRepository) Index

func (repo *GenericRepository) Index(cols []string)

func (*GenericRepository) Query

func (repo *GenericRepository) Query(query interface{}) []GenericModel

func (*GenericRepository) Save

func (repo *GenericRepository) Save(generic GenericModel)

Jump to

Keyboard shortcuts

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