sqlite

package
v0.0.0-...-3a39eda Latest Latest
Warning

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

Go to latest
Published: Aug 30, 2023 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ShortyStorage

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

func NewShortyStorage

func NewShortyStorage(db *sqlx.DB) *ShortyStorage

func (*ShortyStorage) CreateShorty

func (s *ShortyStorage) CreateShorty(ctx context.Context, sh *models.Shorty) error

func (*ShortyStorage) CreateVisit

func (s *ShortyStorage) CreateVisit(ctx context.Context, visit *models.Visit) error

func (*ShortyStorage) GetShorty

func (s *ShortyStorage) GetShorty(ctx context.Context, id string) (*models.Shorty, error)

func (*ShortyStorage) GetVisits

func (s *ShortyStorage) GetVisits(ctx context.Context, shortyID string) ([]models.Visit, error)

type Storage

type Storage struct {
	Shorty *ShortyStorage
}

func NewStorage

func NewStorage(db *sqlx.DB) *Storage

Jump to

Keyboard shortcuts

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