static void Main(string[] args) { OracleCustomerDal.CustomerManager customerManager = new OracleCustomerDal.CustomerManager(); // demo(customerManager); ICustomerDal[] customerDals = new ICustomerDal[3] { new SqlServerCustomerDal(), new OracleCustomerDal(), new OracleCustomerDal.MysqlServerCustomerDal(), }; foreach (var customerDal in customerDals) { customerDal.Add(); } Console.ReadLine(); }
private static void demo(OracleCustomerDal.CustomerManager customerManager) { customerManager.Add(new OracleCustomerDal()); // interface'den çekilen class özellikleri. customerManager.Add(new SqlServerCustomerDal()); // interface'den çekilen class özellikleri. }