Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class DVD implements RetailItem
- {
- private String title;
- private int runningTime;
- private double retailPrice;
- public DVD(String dvdt, int runTime, double dvdp) {
- title = dvdt; runningTime = runTime; retailPrice = dvdp;
- }
- public String getTitle() {
- return title;
- }
- public int getRunTime() {
- return runningTime;
- }
- public double getRetailPrice() {
- return retailPrice;
- }
- public void showPrice(DVD dvd) {
- System.out.println(dvd.getRetailPrice());
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement