/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package sam; /** * * @author mohit */ public abstract class TimsProduct extends Commodity{ private String name; private double cost; private double price; public TimsProduct(String name, double cost, double price){ this.name = name; this.cost = cost; this.price = price; } public String getName(){ return name; } public double getProductionCost(){ return cost; } public double getRetailPrice(){ return price; } public String toString(){ return ("Name is: " + name + "cost is: " + cost + "price is: " + price ); } }