s3-share/internal/db/db.go

16 lines
360 B
Go
Raw Normal View History

2022-05-09 12:52:18 +00:00
package db
import (
"context"
"git.kapelle.org/niklas/s3share/internal/types"
)
type DB interface {
GetShare(ctx context.Context, slug string) (*types.Share, error)
CreateShare(ctx context.Context, share *types.Share) error
DeleteShare(ctx context.Context, slug string) error
2022-05-14 21:25:50 +00:00
GetAllShares(ctx context.Context) ([]*types.Share, error)
2022-05-09 12:52:18 +00:00
Close() error
}