package src.fr.impl.Parts;

import java.util.HashMap;
import java.util.HashSet;
import java.util.Set;

import src.fr.api.PartType;
import src.fr.impl.PartImpl;




public class Interior extends PartImpl { 
     
     private static final HashMap<String,Integer> prices;
     static {
          prices = new HashMap<>();
          prices.put("IN",0);
          prices.put("IH",800);
          prices.put("IS",2500);
      }

     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 Interior(){
     }

     public String getColor(){
          return this.color;
     }

     public void setColor(String newColor){
          this.color = newColor;
     }

     @Override
     public void setType(PartType type){
        this.type = type;
        this.price = prices.get(type.getName());
    }

}
