Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MySQLStorage ¶
type MySQLStorage struct {
Config
}
MySQLStorage represents a storage implementation using MySQL.
func NewMySQLStorage ¶
func NewMySQLStorage(cfg Config) *MySQLStorage
NewMySQLStorage creates a new Image storage.
func (*MySQLStorage) GetImage ¶
func (m *MySQLStorage) GetImage(id int) (*models.Image, error)
GetImage returns an image.
func (*MySQLStorage) GetPersonFromImage ¶
func (m *MySQLStorage) GetPersonFromImage(image string) (*models.Person, error)
GetPersonFromImage returns a person from an image url.
func (*MySQLStorage) UpdateImage ¶
UpdateImage updates an image. There is no check if the person exists or not, because that is happening in GetPersonFromImage.
Click to show internal directories.
Click to hide internal directories.