Created
June 22, 2015 21:35
-
-
Save albuquerquev/4394acb284cdfed04ff5 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Car { | |
private String engine; | |
private String color; | |
private boolean climateControl; | |
private boolean satNav; | |
private boolean sunRoof; | |
public Car(String engine, String color) { | |
this(engine, color, false, false, false); | |
} | |
public Car(String engine, String color, boolean climateControl) { | |
this(engine, color, climateControl, false, false); | |
} | |
public Car(String engine, String color, boolean climateControl, boolean satNav) { | |
this(engine, color, climateControl, satNav, false); | |
} | |
public Car(String engine, String color, boolean climateControl, boolean satNav, boolean sunRoof) { | |
this.engine = engine; | |
this.color = color; | |
this.climateControl = climateControl; | |
this.satNav = satNav; | |
this.sunRoof = sunRoof; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment