storage

package
v0.0.0-...-4bf1c35 Latest Latest
Warning

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

Go to latest
Published: Jan 24, 2017 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Storage

type Storage struct {
	DSN   string
	Table string
}

type Store

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

func New

func New(dialect, dsn string) (*Store, error)

func (*Store) Delete

func (s *Store) Delete(table, key string)

func (*Store) Get

func (s *Store) Get(table, key string) string

func (*Store) Put

func (s *Store) Put(table, key, val string)

func (*Store) Table

func (s *Store) Table(table string)

type Table

type Table struct {
	ID        uint `gorm:"primary_key"`
	CreatedAt time.Time
	UpdatedAt time.Time
	Key       string `gorm:"unique"`
	Val       string
	Table     string `gorm:"-"`
}

func (*Table) TableName

func (t *Table) TableName() string

Jump to

Keyboard shortcuts

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