Movies Section (#338)

Co-authored-by: WithoutPants <53250216+WithoutPants@users.noreply.github.com>
This commit is contained in:
caustico
2020-03-10 04:28:15 +01:00
committed by GitHub
parent b3fab3cfef
commit 5fb8bbf768
79 changed files with 2278 additions and 27 deletions

View File

@@ -0,0 +1,24 @@
package urlbuilders
import "strconv"
type MovieURLBuilder struct {
BaseURL string
MovieID string
}
func NewMovieURLBuilder(baseURL string, movieID int) MovieURLBuilder {
return MovieURLBuilder{
BaseURL: baseURL,
MovieID: strconv.Itoa(movieID),
}
}
func (b MovieURLBuilder) GetMovieFrontImageURL() string {
return b.BaseURL + "/movie/" + b.MovieID + "/frontimage"
}
func (b MovieURLBuilder) GetMovieBackImageURL() string {
return b.BaseURL + "/movie/" + b.MovieID + "/backimage"
}