Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
Functions ¶
This section is empty.
Types ¶
type Repo ¶
type Repo[T any] interface { // Create saves object to the repository. If id already exists // in the database it is an error. Create(ctx context.Context, id string, v *T) error // Read returns object with specified id or ErrNotFound Read(ctx context.Context, id string) (*T, error) // Update updates object with id. Update(ctx context.Context, id string, v *T) error // Delete deletes object from the database. Delete(ctx context.Context, id string) error }
Click to show internal directories.
Click to hide internal directories.