Class SalesData

java.lang.Object
csce331.group13.project2.models.SalesData

public class SalesData extends Object
Represents a row in the sales report, containing information about a menu item's name, quantity sold, and total revenue.
Author:
Hussam Makhoul
  • Property Summary

    Properties
    Type
    Property
    Description
    javafx.beans.property.StringProperty
    Gets the item name property for JavaFX binding.
    javafx.beans.property.IntegerProperty
    Gets the quantity sold property for JavaFX binding.
    javafx.beans.property.DoubleProperty
    Gets the total sales property for JavaFX binding.
  • Constructor Summary

    Constructors
    Constructor
    Description
    SalesData(String itemName, int quantitySold, double totalSales)
    Constructs a SalesData with the specified item name, quantity sold, and total sales.
  • Method Summary

    Modifier and Type
    Method
    Description
    Gets the menu item name.
    int
    Gets the quantity sold.
    double
    Gets the total sales revenue.
    javafx.beans.property.StringProperty
    Gets the item name property for JavaFX binding.
    javafx.beans.property.IntegerProperty
    Gets the quantity sold property for JavaFX binding.
    javafx.beans.property.DoubleProperty
    Gets the total sales property for JavaFX binding.

    Methods inherited from class Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Property Details

  • Constructor Details

    • SalesData

      public SalesData(String itemName, int quantitySold, double totalSales)
      Constructs a SalesData with the specified item name, quantity sold, and total sales.
      Parameters:
      itemName - The name of the menu item.
      quantitySold - The total quantity sold.
      totalSales - The total revenue from this item.
  • Method Details

    • itemNameProperty

      public javafx.beans.property.StringProperty itemNameProperty()
      Gets the item name property for JavaFX binding.
      Returns:
      The item name property.
      See Also:
    • quantitySoldProperty

      public javafx.beans.property.IntegerProperty quantitySoldProperty()
      Gets the quantity sold property for JavaFX binding.
      Returns:
      The quantity sold property.
      See Also:
    • totalSalesProperty

      public javafx.beans.property.DoubleProperty totalSalesProperty()
      Gets the total sales property for JavaFX binding.
      Returns:
      The total sales property.
      See Also:
    • getItemName

      public String getItemName()
      Gets the menu item name.
      Returns:
      The item name.
    • getQuantitySold

      public int getQuantitySold()
      Gets the quantity sold.
      Returns:
      The total quantity sold.
    • getTotalSales

      public double getTotalSales()
      Gets the total sales revenue.
      Returns:
      The total revenue.