Skip to content

Instantly share code, notes, and snippets.

@AnnaBoro
Last active November 10, 2015 16:38
Show Gist options
  • Save AnnaBoro/0801a4c9813d18466560 to your computer and use it in GitHub Desktop.
Save AnnaBoro/0801a4c9813d18466560 to your computer and use it in GitHub Desktop.
shop - Lesson2 - Homework-Frame2
package lesson4.shop;
public class Buyer {
private String name;
private String email;
private int phoneNumber;
public Buyer() {
}
public Buyer(String name, String email, int phoneNumber) {
this.name = name;
this.email = email;
this.phoneNumber = phoneNumber;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getEmail() {
return email;
}
public void setEmail(String email) {
this.email = email;
}
public int getPhoneNumber() {
return phoneNumber;
}
public void setPhoneNumber(int phoneNumber) {
this.phoneNumber = phoneNumber;
}
}
package lesson4.shop;
public class Clothes {
private String name;
private String color;
private int size;
private int price;
public Clothes() {
}
public Clothes(String name, String color, int size, int price) {
this.name = name;
this.color = color;
this.size = size;
this.price = price;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getColor() {
return color;
}
public void setColor(String color) {
this.color = color;
}
public int getSize() {
return size;
}
public void setSize(int size) {
this.size = size;
}
public int getPrice() {
return price;
}
public void setPrice(int price) {
this.price = price;
}
}
package lesson4.shop;
public class Purchase {
private Clothes product;
private Buyer buyer;
private int date;
public Purchase() {
}
public Purchase(Clothes product, int date, Buyer buyer) {
this.product = product;
this.date = date;
this.buyer = buyer;
}
public Clothes getProduct() {
return product;
}
public void setProduct(Clothes product) {
this.product = product;
}
public Buyer getBuyer() {
return buyer;
}
public void setBuyer(Buyer buyer) {
this.buyer = buyer;
}
public int getDate() {
return date;
}
public void setDate(int date) {
this.date = date;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment