public WebUrl Movies(SearchParamters paramters) { return(BaseUrl .WithParameter("q", paramters.Query) .AppendToPath("movies") .WithParameter("page", paramters.PageNumber) .WithParameter("page_limit", paramters.PageSize)); }
public IEnumerable <RTMovie> SearchMovies(SearchParamters parameters) { if (!parameters.HasQuery) { return(Enumerable.Empty <RTMovie>()); } var url = _urls.Movies(parameters); var result = _reader.Get(url.ToString()); var movieList = result.FromJsonTo <RTMovieList>(); return(movieList.movies); }