Write a program that manipulates a database of product records. Records are stored in a binary file. Each record consists of these items:

The program should allow the user to add a record, find a record that matches a product name, and change the price and quantity of a product by a given amount.

Complete the following files:

ProductData.java

ProductDataEditor.java

Use the following file:

Product.java

public class Product
{  
   private String name;
   private double price;
   private int quantity;

   /**
      Constructs a product with empty name and 0 price and
      quantity.
   */
   public Product()
   {  
      name = "";
      price = 0;
      quantity = 0;
   }
   
   /**
      Constructs a product with the given name, price and 
      quantity.
      @param aName product name
      @param aPrice product price
      @param aQuantity product quantity
   */
   public Product(String aName, double aPrice, int aQuantity)
   {  
      name = aName;
      price = aPrice;
      quantity = aQuantity;
   }

   /**
      Returns the product name.
      @return the product name
   */
   public String getName()
   {  
      return name;
   }
   
   /**
      Returns the product price.
      @return the product price
   */
   public double getPrice()
   {  
      return price;
   }
   
   /**
      Returns the product quantity.
      @return the product quantity
   */
   public int getQuantity()
   {  
      return quantity;
   }
   
   /**
      Sets the product price.
      @param newPrice the new product price
   */
   public void setPrice(double newPrice)
   {  
      price = newPrice;
   }

   /**
      Sets the product quantity.
      @param newQuantity the new product quantity
   */
   public void setQuantity(int newQuantity)
   {  
      quantity = newQuantity;
   }
}