diff --git a/src/opinion/Book.java b/src/opinion/Book.java index 7f6ebe0881bf1faae2ea54b85bc147b23c7e6bbd..4ac8218fc20b26400bbef747a4523d616f11a65b 100644 --- a/src/opinion/Book.java +++ b/src/opinion/Book.java @@ -35,7 +35,7 @@ public class Book extends Item{ } /** - * <b>Return the title of the book</b> + * Return the title of the book * * @return book's title */ @@ -44,7 +44,7 @@ public class Book extends Item{ } /** - * <b>Return the kind of the book</b> + * Return the kind of the book * * @return book's kind */ @@ -53,7 +53,7 @@ public class Book extends Item{ } /** - * <b>Retrieve the author of the book</b> + * Return the author of the book * * @return book's author */ @@ -62,7 +62,7 @@ public class Book extends Item{ } /** - * <b>Return the number of pages of the book</b> + * Return the number of pages of the book * * @return book's page number */ @@ -72,18 +72,14 @@ public class Book extends Item{ - - - - /** - * <b>String function to display the details of a book</b> + * String function to display the details of a book * * @return the book's details */ public String toString() { String text = "Book : " + getTitle() + "\nKind : " + getKind() + "\nAuthor : " + getAuthor() + "\nNumber of pages : " + getNbPages()+"\nOverall note: "+getAverageMark() +"\nReviews"; - int counter = 1; + //int counter = 1; //for (Review r : reviews) { // text += counter + ". " + r.getReviewerLogin() + "\t" + r.getMark() + "\t" + r.getComment(); // counter++; diff --git a/src/opinion/Film.java b/src/opinion/Film.java index d0cc09cdf64cf4c8f9a9f94e4577daba1cb2e877..6dd31b12ce3be43b8df82378af03cacf31bbab6c 100644 --- a/src/opinion/Film.java +++ b/src/opinion/Film.java @@ -1,20 +1,15 @@ package opinion; -import java.util.LinkedList; - public class Film extends Item { private String director; private String scenarist; private int duration; - - public Film(String title, String kind, String director, String scenarist, int duration) { super(title, kind); this.director = director.trim(); this.scenarist = scenarist.trim(); this.duration = duration; - } public String getDirector() { diff --git a/src/tests/AddItemBookTest.java b/src/tests/AddItemBookTest.java index 07dc4b9c15e3d872b6cc30a4e119164352c8f3f5..bbc9aa0e6873a8ba42297efe973af99ac37bb2f5 100644 --- a/src/tests/AddItemBookTest.java +++ b/src/tests/AddItemBookTest.java @@ -1,12 +1,8 @@ package tests; +import exceptions.*; import opinion.ISocialNetwork; import opinion.SocialNetwork; -import exceptions.BadEntryException; -import exceptions.MemberAlreadyExistsException; -import exceptions.NotMemberException; -import exceptions.ItemBookAlreadyExistsException; -import exceptions.NotTestReportException; /** * Tests for the SocialNetwork.<i>addItemBook()</i> method.