ajustement des prix

This commit is contained in:
trochas
2024-12-04 17:46:11 +01:00
parent f9c6059067
commit 503d24f140
2 changed files with 37 additions and 7 deletions

View File

@@ -1,11 +1,41 @@
package src.fr.impl.Parts;
import java.util.HashSet;
import java.util.Set;
import src.fr.impl.CategoryImpl;
import src.fr.impl.PartImpl;
import src.fr.impl.PartTypeImpl;
public class Interior extends PartImpl {
public class Interior extends PartImpl {
private static final Set<String> colorSet;
static {
colorSet = new HashSet<>();
colorSet.add("black");
colorSet.add("white");
colorSet.add("cream");
}
String color;
String material;
public Interior(String name, CategoryImpl category, int price){
super(new PartTypeImpl(name,Engine.class, category), price);
}
public String getColor(){
return this.color;
}
public void setColor(String newColor){
this.color = newColor;
}
}