Exemple #1
0
        public static void MethodInjection()
        {
            OutlookEmailService outlookEmailService = new OutlookEmailService();
            UserLogic           userLogic           = new UserLogic();

            userLogic.Register(email, message, outlookEmailService);
        }
Exemple #2
0
        public static void SetterInjection()
        {
            OutlookEmailService outlookEmailService = new OutlookEmailService();
            UserLogic           userLogic           = new UserLogic()
            {
                EmailService = outlookEmailService
            };

            userLogic.Register(email, message);
        }