1 Commits
Author SHA1 Message Date
reyhne 4bd003b929 Merge pull request 'Movie Explorer + Rational Calculator' (#1) from develop into main
Reviewed-on: #1
2026-05-07 14:06:50 +00:00
2 changed files with 22 additions and 6 deletions
+17 -5
View File
@@ -14,7 +14,7 @@ public class Movie
private String imdb_votes; private String imdb_votes;
private String director; private String director;
private String actors; private List<String> actors;
private String runtime; private String runtime;
private String rated; private String rated;
private String released; private String released;
@@ -136,16 +136,25 @@ public class Movie
this.director = director; this.director = director;
} }
public String getActors() {return actors;} public List<String> getActors()
{
return actors;
}
public void setActors(String actors) {this.actors = actors;} public void setActors(List<String> actors)
{
this.actors = actors;
}
public String getRuntime() public String getRuntime()
{ {
return runtime; return runtime;
} }
public void setRuntime(String runtime) {this.runtime = runtime;} public void setRuntime(String runtime)
{
this.runtime = runtime;
}
public String getRated() public String getRated()
{ {
@@ -162,7 +171,10 @@ public class Movie
return released; return released;
} }
public void setReleased(String released) {this.released = released;} public void setReleased(String released)
{
this.released = released;
}
public String getPlot() public String getPlot()
{ {
+5 -1
View File
@@ -176,9 +176,13 @@ public class MovieService
System.out.println("======================================================================"); System.out.println("======================================================================");
System.out.println("Rating: " + movie.getImdb_rating() + "/10 | Votes: " + movie.getImdb_votes()); System.out.println("Rating: " + movie.getImdb_rating() + "/10 | Votes: " + movie.getImdb_votes());
System.out.println("Director: " + movie.getDirector()); System.out.println("Director: " + movie.getDirector());
System.out.println("Cast: " + movie.getActors());
String cast = (movie.getActors() != null) ? String.join(", ", movie.getActors()) : "";
System.out.println("Cast: " + cast);
String genresText = (movie.getGenres() != null) ? String.join(", ", movie.getGenres()) : ""; String genresText = (movie.getGenres() != null) ? String.join(", ", movie.getGenres()) : "";
System.out.println("Genre: " + genresText); System.out.println("Genre: " + genresText);
System.out.println("Runtime: " + movie.getRuntime() + " | Rated: " + movie.getRated()); System.out.println("Runtime: " + movie.getRuntime() + " | Rated: " + movie.getRated());
System.out.println("Country: " + movie.getCountry() + " | Released: " + movie.getReleased()); System.out.println("Country: " + movie.getCountry() + " | Released: " + movie.getReleased());
System.out.println("Plot: " + movie.getPlot()); System.out.println("Plot: " + movie.getPlot());