2 * Copyright (C) 2016 - 2024 Free Software Foundation
4 * This program is free software: you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation, either version 3 of the License, or
7 * (at your option) any later version.
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
17 package org.mxchange.jfinancials.model.receipt_item;
19 import java.io.Serializable;
20 import java.math.BigDecimal;
21 import java.util.Date;
22 import org.mxchange.jcontactsbusiness.model.basicdata.BasicData;
23 import org.mxchange.jfinancials.model.receipt.BillableReceipt;
24 import org.mxchange.jproduct.model.product.Product;
27 * An interface for receipt items
29 * @author Roland Häder<roland@mxchange.org>
31 public interface BillableReceiptItem extends Comparable<BillableReceiptItem>, Serializable {
34 * Getter for primary key
41 * Setter for primary key
43 * @param itemId Primary key
45 void setItemId (final Long itemId);
48 * Getter for whether the item is a discount on whole receipt
50 * @return Whether the item is a discount on whole receipt
52 Boolean getItemIsDiscount ();
55 * Setter for whether the item is a discount on whole receipt or item
57 * @param itemIsDiscount Whether the item is a discount on whole receipt or
60 void setItemIsDiscount (final Boolean itemIsDiscount);
63 * Getter for whether the item is a refund
65 * @return Whether the item is a refund
67 Boolean getItemIsRefund ();
70 * Setter for whether the item is a refund
72 * @param itemIsRefund Whether the item is a refund
74 void setItemIsRefund (final Boolean itemIsRefund);
77 * Getter for receipt instance
79 * @return Receipt instance
81 BillableReceipt getItemReceipt ();
84 * Setter for receipt instance
86 * @param itemReceipt Receipt instance
88 void setItemReceipt (final BillableReceipt itemReceipt);
91 * Getter for linked product
95 Product getItemProduct ();
98 * Setter for linked product
100 * @param itemProduct Product
102 void setItemProduct (final Product itemProduct);
105 * Getter for product quantity
107 * @return Product quantity
109 BigDecimal getItemProductQuantity ();
112 * Setter for product quantity
114 * @param itemProductQuantity Product quantity
116 void setItemProductQuantity (final BigDecimal itemProductQuantity);
119 * Getter for item's net price
121 * @return Item's net price
123 BigDecimal getItemNetPrice ();
126 * Setter for item's net price
128 * @param itemNetPrice Item's net price
130 void setItemNetPrice (final BigDecimal itemNetPrice);
133 * Getter for item's tax rate
135 * @return Item's tax rate
137 BigDecimal getItemTaxRate ();
140 * Setter for item's tax rate
142 * @param itemTaxRate Item's tax rate
144 void setItemTaxRate (final BigDecimal itemTaxRate);
147 * Getter for item's gross price
149 * @return Item's gross price
151 BigDecimal getItemGrossPrice ();
154 * Setter for item's gross price
156 * @param itemGrossPrice Item's gross price
158 void setItemGrossPrice (final BigDecimal itemGrossPrice);
161 * Getter for manufacturer/producer of this item
163 * @return Manufacturer/producer of this item
165 BasicData getItemManufacturer ();
168 * Setter for manufacturer/producer of this item
170 * @param itemManufacturer Manufacturer/producer of this item
172 void setItemManufacturer (final BasicData itemManufacturer);
175 * Getter for item brand name
177 * @return Item brand name
179 String getItemBrandName ();
182 * Setter for item brand name
184 * @param itemBrandName Item brand name
186 void setItemBrandName (final String itemBrandName);
189 * Getter for item number
191 * @return Item number
193 Long getItemNumber ();
196 * Setter for item number
198 * @param itemNumber Item number
200 void setItemNumber (final Long itemNumber);
203 * Getter for item's coupon number
205 * @return Item's coupon number
207 String getItemCouponNumber ();
210 * Setter for item's coupon number
212 * @param itemCouponNumber Item's coupon number
214 void setItemCouponNumber (final String itemCouponNumber);
217 * Getter when this receipt item has been created in database
219 * @return When this item has been created
221 Date getItemEntryCreated ();
224 * Setter when this receipt item has been updated in database
226 * @param itemEntryCreated When this item has been updated
228 void setItemEntryCreated (final Date itemEntryCreated);
231 * Getter when this receipt item has been updated in database
233 * @return When this item has been updated
235 Date getItemEntryUpdated ();
238 * Setter when this receipt item has been updated in database
240 * @param itemEntryUpdated When this item has been updated
242 void setItemEntryUpdated (final Date itemEntryUpdated);
245 boolean equals (final Object object);