Advertisement
Guest User

Book

a guest
Jun 23rd, 2016
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.02 KB | None | 0 0
  1. public class Book {
  2.  
  3. private String author;
  4. private String title;
  5. private double price;
  6. private String image;
  7.  
  8.  
  9. /** Konstruktor tworzący
  10. * @param author autor
  11. * @param title tutył książki
  12. * @param price cena książki
  13. * @param image
  14. */
  15. public Book(String author, String title, double price, String image) {
  16. super();
  17. this.author = author;
  18. this.title = title;
  19. this.price = price;
  20. this.image = image;
  21. }
  22.  
  23. public Book() {
  24. super();
  25. this.author="";
  26. this.title="";
  27. this.price=0;
  28. this.image = "";
  29. }
  30.  
  31. public String getImage(){
  32. return image;
  33. }
  34.  
  35. public void setImage(String image){
  36. this.image = image;
  37. }
  38.  
  39. public String getAuthor() {
  40. return author;
  41. }
  42. public void setAuthor(String author) {
  43. this.author = author;
  44. }
  45. public String getTitle() {
  46. return title;
  47. }
  48. public void setTitle(String title) {
  49. this.title = title;
  50. }
  51. public double getPrice() {
  52. return price;
  53. }
  54. public void setPrice(double price) {
  55. this.price = price;
  56. }
  57.  
  58. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement