internal

package
v0.0.0-...-9af082e Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ErrMethodNotAllowed = "status method not allowed"
	ErrIDRequired       = "ID must be provided for update"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Handler

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

func NewHandler

func NewHandler() *Handler

func (*Handler) Invoke

func (h *Handler) Invoke(ctx context.Context, req Request) (Response, error)

Invoke processes the request and calls the corresponding method.

type Item

type Item struct {
	Id   string `json:"id"`
	Name string `json:"name"`
}

type ItemRepository

type ItemRepository interface {
	FindAll() ([]*Item, error)
	Save(ctx context.Context, item Item) error
	Delete(ctx context.Context, id string) error
}

func NewDdbItemRepository

func NewDdbItemRepository() ItemRepository

Jump to

Keyboard shortcuts

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