stash/pkg/api/urlbuilders/performer.go

20 lines
424 B
Go
Raw Normal View History

2019-02-09 12:30:49 +00:00
package urlbuilders
import "strconv"
type PerformerURLBuilder struct {
BaseURL string
2019-02-09 12:30:49 +00:00
PerformerID string
}
func NewPerformerURLBuilder(baseURL string, performerID int) PerformerURLBuilder {
return PerformerURLBuilder{
BaseURL: baseURL,
2019-02-09 12:30:49 +00:00
PerformerID: strconv.Itoa(performerID),
}
}
func (b PerformerURLBuilder) GetPerformerImageURL() string {
2019-02-09 12:30:49 +00:00
return b.BaseURL + "/performer/" + b.PerformerID + "/image"
}