summaryrefslogtreecommitdiff
path: root/oop/11-point-of-sale/src/main/java/lk/ac/pdn/ceit/pos/entities/LineItem.java
blob: 8c53ec4f4600f0a375b9062f64f0c946f72dade5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
package lk.ac.pdn.ceit.pos.entities;

import java.math.BigDecimal;

public class LineItem {

    private String itemId;
    private String itemName;
    private int quantity;
    private BigDecimal unitPrice;
    
    public LineItem() {
    }

    public LineItem(String itemId, String itemName, int quantity, BigDecimal unitPrice) {
        this.itemId = itemId;
        this.itemName = itemName;
        this.quantity = quantity;
        this.unitPrice = unitPrice;
    }

    public String getItemId() {
        return itemId;
    }
    public void setItemId(String itemId) {
        this.itemId = itemId;
    }
    public String getItemName() {
        return itemName;
    }
    public void setItemName(String itemName) {
        this.itemName = itemName;
    }
    public int getQuantity() {
        return quantity;
    }
    public void setQuantity(int quantity) {
        this.quantity = quantity;
    }
    public BigDecimal getUnitPrice() {
        return unitPrice;
    }
    public void setUnitPrice(BigDecimal unitPrice) {
        this.unitPrice = unitPrice;
    }

    @Override
    public String toString() {
        return "LineItem [itemId=" + itemId + ", itemName=" + itemName + ", quantity=" + quantity + ", unitPrice="
                + unitPrice + "]";
    }
    
}