📄 cartitem.java
字号:
package com.j2eeapp.cdstore.cart;
import java.io.Serializable;
public class CartItem implements Serializable {
private String itemId;
private String productId;
private String category;
private String name;
private String attribute;
private int quantity;
private float unitCost;
public CartItem(String itemId, String productId, String category, String name,
String attribute, int quantity, float unitCost) {
this.category = category;
this.itemId = itemId;
this.productId = productId;
this.name = name;
this.attribute = attribute;
this.quantity = quantity;
this.unitCost = unitCost;
}
public String getCategory() {
return category;
}
public String getItemId() {
return itemId;
}
public String getProductId() {
return productId;
}
public String getName() {
return name;
}
public String getAttribute() {
return attribute;
}
public int getQuantity() {
return quantity;
}
public float getUnitCost() {
return unitCost;
}
public double getTotalCost() {
return quantity * unitCost;
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -