Documentation
¶
Index ¶
- func HasTransaction(ctx context.Context, tx *gorm.DB) *gorm.DB
- type FileAccessStore
- type FileStore
- type PostgresFileAccessStore
- func (r *PostgresFileAccessStore) DB() *gorm.DB
- func (r *PostgresFileAccessStore) DeleteByID(ctx context.Context, id uint) error
- func (r *PostgresFileAccessStore) FindByHash(ctx context.Context, hash string) (*domain.FileAccess, error)
- func (r *PostgresFileAccessStore) FindByID(ctx context.Context, id uint) (*domain.FileAccess, error)
- func (r *PostgresFileAccessStore) Save(ctx context.Context, fileAccess *domain.FileAccess) error
- type PostgresFileStore
- type PostgresUserStore
- func (r *PostgresUserStore) DB() *gorm.DB
- func (r *PostgresUserStore) DeleteByID(ctx context.Context, id uint) error
- func (r *PostgresUserStore) FindAll(ctx context.Context) []*domain.User
- func (r *PostgresUserStore) FindByEmail(ctx context.Context, email string) (*domain.User, error)
- func (r *PostgresUserStore) FindByID(ctx context.Context, id uint) (*domain.User, error)
- func (r *PostgresUserStore) Save(ctx context.Context, user *domain.User) error
- type UserStore
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type FileAccessStore ¶
type FileAccessStore interface { DB() *gorm.DB FindByID(ctx context.Context, id uint) (*domain.FileAccess, error) FindByHash(ctx context.Context, hash string) (*domain.FileAccess, error) Save(ctx context.Context, fileAccess *domain.FileAccess) error DeleteByID(ctx context.Context, id uint) error }
func NewPostgresFileAccessStore ¶
func NewPostgresFileAccessStore(db *gorm.DB) FileAccessStore
type FileStore ¶
type FileStore interface { DB() *gorm.DB FindByID(ctx context.Context, id uint) (*domain.File, error) Save(ctx context.Context, file *domain.File) error DeleteByID(ctx context.Context, id uint) error }
func NewPostgresFileStore ¶
type PostgresFileAccessStore ¶
type PostgresFileAccessStore struct {
// contains filtered or unexported fields
}
func (*PostgresFileAccessStore) DB ¶
func (r *PostgresFileAccessStore) DB() *gorm.DB
func (*PostgresFileAccessStore) DeleteByID ¶
func (r *PostgresFileAccessStore) DeleteByID(ctx context.Context, id uint) error
func (*PostgresFileAccessStore) FindByHash ¶
func (r *PostgresFileAccessStore) FindByHash(ctx context.Context, hash string) (*domain.FileAccess, error)
func (*PostgresFileAccessStore) FindByID ¶
func (r *PostgresFileAccessStore) FindByID(ctx context.Context, id uint) (*domain.FileAccess, error)
func (*PostgresFileAccessStore) Save ¶
func (r *PostgresFileAccessStore) Save(ctx context.Context, fileAccess *domain.FileAccess) error
type PostgresFileStore ¶
type PostgresFileStore struct {
// contains filtered or unexported fields
}
func (*PostgresFileStore) DB ¶
func (r *PostgresFileStore) DB() *gorm.DB
func (*PostgresFileStore) DeleteByID ¶
func (r *PostgresFileStore) DeleteByID(ctx context.Context, id uint) error
type PostgresUserStore ¶
type PostgresUserStore struct {
// contains filtered or unexported fields
}
func (*PostgresUserStore) DB ¶
func (r *PostgresUserStore) DB() *gorm.DB
func (*PostgresUserStore) DeleteByID ¶
func (r *PostgresUserStore) DeleteByID(ctx context.Context, id uint) error
func (*PostgresUserStore) FindAll ¶
func (r *PostgresUserStore) FindAll(ctx context.Context) []*domain.User
func (*PostgresUserStore) FindByEmail ¶
type UserStore ¶
type UserStore interface { DB() *gorm.DB FindAll(ctx context.Context) []*domain.User FindByID(ctx context.Context, id uint) (*domain.User, error) FindByEmail(ctx context.Context, email string) (*domain.User, error) Save(ctx context.Context, user *domain.User) error DeleteByID(ctx context.Context, uuid uint) error }
func NewPostgresUserStore ¶
Click to show internal directories.
Click to hide internal directories.