class ClosedTabItem { final String id; final String closedTabId; final String productId; final String productName; final int quantity; final int unitPriceInCents; ClosedTabItem({ required this.id, required this.closedTabId, required this.productId, required this.productName, required this.quantity, required this.unitPriceInCents, }); int get lineTotalInCents => quantity * unitPriceInCents; @override bool operator ==(Object other) => identical(this, other) || other is ClosedTabItem && id == other.id && closedTabId == other.closedTabId && productId == other.productId && productName == other.productName && quantity == other.quantity && unitPriceInCents == other.unitPriceInCents; @override int get hashCode => Object.hash( id, closedTabId, productId, productName, quantity, unitPriceInCents, ); }