string TypeForComponent(ComponentType component) { switch (component) { case ComponentType.Dough: return "dough"; case ComponentType.Sauce: return "sauce"; case ComponentType.Topping: return "topping"; default: throw new Exception (); } }