2017-08-18 03:20:23 +05:30
|
|
|
package interfaces
|
2017-08-09 21:49:46 +05:30
|
|
|
|
2017-08-18 03:20:23 +05:30
|
|
|
import (
|
2019-04-27 04:16:15 +05:30
|
|
|
"github.com/elyby/chrly/api/mojang"
|
2018-02-16 02:43:57 +05:30
|
|
|
"github.com/elyby/chrly/model"
|
2017-08-18 03:20:23 +05:30
|
|
|
)
|
2017-08-09 21:49:46 +05:30
|
|
|
|
|
|
|
type SkinsRepository interface {
|
2017-08-17 05:17:35 +05:30
|
|
|
FindByUsername(username string) (*model.Skin, error)
|
|
|
|
FindByUserId(id int) (*model.Skin, error)
|
|
|
|
Save(skin *model.Skin) error
|
2018-01-23 21:13:37 +05:30
|
|
|
RemoveByUserId(id int) error
|
|
|
|
RemoveByUsername(username string) error
|
2017-08-09 21:49:46 +05:30
|
|
|
}
|
2017-08-18 03:20:23 +05:30
|
|
|
|
|
|
|
type CapesRepository interface {
|
2017-08-20 03:52:42 +05:30
|
|
|
FindByUsername(username string) (*model.Cape, error)
|
2017-08-18 03:20:23 +05:30
|
|
|
}
|
2019-04-27 04:16:15 +05:30
|
|
|
|
|
|
|
type MojangTexturesQueue interface {
|
|
|
|
GetTexturesForUsername(username string) chan *mojang.SignedTexturesResponse
|
|
|
|
}
|