private static Printer CreatePrinter() { var factory = new PrinterFactory(); System.Console.WriteLine("Enter printer name"); string name = System.Console.ReadLine(); System.Console.WriteLine("Enter printer model"); string model = System.Console.ReadLine(); System.Console.WriteLine("Type:"); string intype = System.Console.ReadLine(); Enum.TryParse(intype, true, out PrinterTypes type); Printer printer = factory.Get(name, model, type); return(printer); }