postgres

package
v0.0.5 Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsDuplicatedKeyError

func IsDuplicatedKeyError(err error) bool

func IsNotFoundError

func IsNotFoundError(err error) bool

Types

type Storage

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

func NewStorage

func NewStorage(cfg *config.Config) (*Storage, error)

func (*Storage) CloseStorage

func (s *Storage) CloseStorage()

func (*Storage) DeleteURL

func (s *Storage) DeleteURL(ctx context.Context, alias string) error

func (*Storage) GetURL

func (s *Storage) GetURL(ctx context.Context, alias string) (string, error)

func (*Storage) SaveURL

func (s *Storage) SaveURL(ctx context.Context, urlToSave string, alias string) error

Jump to

Keyboard shortcuts

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