dynamodb_example

package
v0.0.0-...-25c0598 Latest Latest
Warning

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

Go to latest
Published: Sep 14, 2018 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(db dynamodb.DynamoDB) *repo

Types

type Getter

type Getter interface {
	Get(ctx context.Context, id string) (*models.Thing, error)
}

type GetterFunc

type GetterFunc func(ctx context.Context, id string) (*models.Thing, error)

func (GetterFunc) Get

func (f GetterFunc) Get(ctx context.Context, id string) (*models.Thing, error)

type MultiGetter

type MultiGetter interface {
	GetMulti(ctx context.Context, ids ...string) ([]*models.Thing, error)
}

type MultiGetterFunc

type MultiGetterFunc func(ctx context.Context, ids ...string) ([]*models.Thing, error)

func (MultiGetterFunc) GetMulti

func (f MultiGetterFunc) GetMulti(ctx context.Context, ids ...string) ([]*models.Thing, error)

type Putter

type Putter interface {
	Put(ctx context.Context, t *models.Thing) error
}

type PutterFunc

type PutterFunc func(ctx context.Context, t *models.Thing) error

func (PutterFunc) Put

func (f PutterFunc) Put(ctx context.Context, t *models.Thing) error

type Repo

type Repo interface {
	Getter
	MultiGetter
	Putter
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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