Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class Guitar {
- private String serialNumber;
- private double price;
- GuitarSpec spec;
- public Guitar(String serialNumber, double price,
- GuitarSpec specs) {
- this.serialNumber = serialNumber;
- this.price = price;
- this.spec = specs;
- }
- public String getSerialNumber() {
- return serialNumber;
- }
- public double getPrice() {
- return price;
- }
- public void setPrice(float newPrice) {
- this.price = newPrice;
- }
- public GuitarSpec getSpec() {
- return spec;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement