コード例 #1
0
        public static Movie getMovieByID(int id)
        {
            MovieSearcher.SearcherSoapClient searcher = new MovieSearcher.SearcherSoapClient("SearcherSoap");
            MovieSearcher.Movie movie = searcher.getMovieByID(id);
            Movie m = new Movie(movie.Id, movie.Title, movie.Genre, movie.YearPublished, movie.AgeRating, movie.DirectorName, movie.Actors.ToList <String>());

            return(m);
        }
コード例 #2
0
        public static List <Movie> getAllMoviesAsList()
        {
            MovieSearcher.SearcherSoapClient searcher = new MovieSearcher.SearcherSoapClient("SearcherSoap");
            List <MovieSearcher.Movie>       movies   = searcher.getAllMovies().ToList <MovieSearcher.Movie>();
            List <Movie> ms = new List <Movie>();

            foreach (MovieSearcher.Movie movie in movies)
            {
                Movie m = convertFromWebService(movie);
                ms.Add(m);
            }
            return(ms);
        }
コード例 #3
0
        public static List <Movie> getMoviesByTitle(string title)
        {
            MovieSearcher.SearcherSoapClient searcher = new MovieSearcher.SearcherSoapClient("SearcherSoap");
            List <MovieSearcher.Movie>       movies   = searcher.getMoviesByTitle(title).ToList <MovieSearcher.Movie>();
            List <Movie> ms = new List <Movie>();

            foreach (MovieSearcher.Movie movie in movies)
            {
                Movie m = convertFromWebService(movie);
                ms.Add(m);
            }
            return(ms);
        }