18 lines
397 B
Go
18 lines
397 B
Go
package image
|
|
|
|
type SearchQuery struct {
|
|
Search string
|
|
Hash string
|
|
}
|
|
|
|
type Repository interface {
|
|
Create(input ImageInput) (Image, error)
|
|
Get(id uint32) (Image, error)
|
|
Delete(id uint32) error
|
|
List(query SearchQuery) ([]Image, error)
|
|
FindByHash(hash string) ([]Image, error)
|
|
Rename(id uint32, filename string) (Image, error)
|
|
ListDuplicates() ([]Image, error)
|
|
Counts() (Counts, error)
|
|
}
|