persons

package
v0.0.0-...-bf94844 Latest Latest
Warning

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

Go to latest
Published: Jun 10, 2021 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Repository

type Repository interface {
	Close() error
	Find(ctx context.Context, limit int) ([]entity.Person, error)
	FindOne(ctx context.Context, id int64) (*entity.Person, error)
	SavePerson(ctx context.Context, person entity.Person) (int64, error)
}

Repository declares and summarizes the functionality a repository in the containing package will implement

type Service

type Service interface {
	Persons(ctx context.Context, limit int) ([]entity.Person, error)
	Person(ctx context.Context, id int64) (*entity.Person, error)
	SavePerson(ctx context.Context, name string, age int) (int64, error)
}

Service declares and summarizes the functionality a service in the containing package will implement

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳