Documentation ¶
Index ¶
- type DB
- type RecordStore
- func (s *RecordStore) GetMedia(ctx context.Context, id string) (*model.MediaRecord, error)
- func (s *RecordStore) InsertMedia(ctx context.Context, m *model.MediaRecord) (*model.MediaRecord, error)
- func (s *RecordStore) UpdateMedia(ctx context.Context, m *model.MediaRecord) (*model.MediaRecord, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DB ¶
type DB interface { NamedQueryContext(ctx context.Context, query string, arg interface{}) (*sqlx.Rows, error) GetContext(ctx context.Context, dest interface{}, query string, args ...interface{}) error NamedExecContext(ctx context.Context, query string, arg interface{}) (sql.Result, error) ExecContext(ctx context.Context, query string, args ...interface{}) (sql.Result, error) QueryxContext(ctx context.Context, query string, args ...interface{}) (*sqlx.Rows, error) }
DB represents a type for interfacing with a database.
type RecordStore ¶
type RecordStore struct {
// contains filtered or unexported fields
}
RecordStore provides functionality for working with a database.
func (*RecordStore) GetMedia ¶
func (s *RecordStore) GetMedia(ctx context.Context, id string) (*model.MediaRecord, error)
func (*RecordStore) InsertMedia ¶
func (s *RecordStore) InsertMedia(ctx context.Context, m *model.MediaRecord) (*model.MediaRecord, error)
func (*RecordStore) UpdateMedia ¶
func (s *RecordStore) UpdateMedia(ctx context.Context, m *model.MediaRecord) (*model.MediaRecord, error)
Click to show internal directories.
Click to hide internal directories.