You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
63 lines
1.4 KiB
63 lines
1.4 KiB
package JavaBean;
|
|
|
|
public class Shopcar {
|
|
private int userId;
|
|
private Integer bookid;
|
|
private Integer number;
|
|
private int itemid;
|
|
|
|
public int getUserId() {
|
|
return userId;
|
|
}
|
|
|
|
public void setUserId(int userId) {
|
|
this.userId = userId;
|
|
}
|
|
|
|
public Integer getBookid() {
|
|
return bookid;
|
|
}
|
|
|
|
public void setBookid(Integer bookid) {
|
|
this.bookid = bookid;
|
|
}
|
|
|
|
public Integer getNumber() {
|
|
return number;
|
|
}
|
|
|
|
public void setNumber(Integer number) {
|
|
this.number = number;
|
|
}
|
|
|
|
@Override
|
|
public boolean equals(Object o) {
|
|
if (this == o) return true;
|
|
if (o == null || getClass() != o.getClass()) return false;
|
|
|
|
Shopcar shopcar = (Shopcar) o;
|
|
|
|
if (userId != shopcar.userId) return false;
|
|
if (bookid != null ? !bookid.equals(shopcar.bookid) : shopcar.bookid != null) return false;
|
|
if (number != null ? !number.equals(shopcar.number) : shopcar.number != null) return false;
|
|
|
|
return true;
|
|
}
|
|
|
|
@Override
|
|
public int hashCode() {
|
|
int result = userId;
|
|
result = 31 * result + (bookid != null ? bookid.hashCode() : 0);
|
|
result = 31 * result + (number != null ? number.hashCode() : 0);
|
|
return result;
|
|
}
|
|
|
|
public int getItemid() {
|
|
return itemid;
|
|
}
|
|
|
|
public void setItemid(int itemid) {
|
|
this.itemid = itemid;
|
|
}
|
|
}
|