Git Repository Public Repository

RRRRHHHH_Code

URLs

Copy to Clipboard

Diff Revisions 85d983 ... vs d30bcc ... for ruralHouses/src/domain/Booking.java

Diff revisions: vs.
  @@ -3,7 +3,7 @@
3 3 import java.io.Serializable;
4 4 import java.util.Date;
5 5
6 - public class Booking implements Serializable {
6 + public class Booking implements Serializable {
7 7
8 8 /**
9 9 *
  @@ -13,30 +13,18 @@
13 13 private Date bookingDate;
14 14 private Client client;
15 15 private Offer offer;
16 -
17 - public Booking(int bN, Offer offer, Client client, Date date) {
16 +
17 +
18 +
19 + public Booking(int bN , Offer offer,Client client) {
20 +
18 21 this.bookingNumber = bN;
19 22 this.offer = offer;
20 - this.client = client;
21 - // Booking date is assigned to actual date
22 - this.bookingDate = date;
23 - }
24 -
25 - public Booking(int bN, Offer offer, Client client) {
26 -
27 - this.bookingNumber = bN;
28 - this.offer = offer;
29 - this.client = client;
30 - // Booking date is assigned to actual date
31 - this.bookingDate = new java.util.Date(System.currentTimeMillis());
32 - }
33 -
34 - public void imprimete() {
35 - System.out.println(bookingNumber);
36 - System.out.println(bookingDate);
37 - System.out.println(client.toString());
38 - System.out.println(offer);
23 + this.client=client;
24 + //Booking date is assigned to actual date
25 + this.bookingDate= new java.util.Date(System.currentTimeMillis());
39 26 }
27 +
40 28
41 29 public int getBookNumber() {
42 30 return this.bookingNumber;
  @@ -50,9 +38,6 @@
50 38 return this.offer;
51 39 }
52 40
53 - public float getPrice() {
54 - return this.offer.getPrice();
55 - }
56 41
57 42 public void setBookDate(Date bookDate) {
58 43 this.bookingDate = bookDate;
  @@ -61,7 +46,7 @@
61 46 public Date getBookDate() {
62 47 return this.bookingDate;
63 48 }
64 -
49 +
65 50 public Client getClient() {
66 51 return client;
67 52 }
  @@ -69,5 +54,5 @@
69 54 public void setClient(Client client) {
70 55 this.client = client;
71 56 }
72 -
57 +
73 58 }