コード例 #1
0
        public void When執行EF通知檢查作業()
        {
            var strategy = new GenericNotifierStrategy();

            _notificationDirector = new NotificationDirectorFake(strategy, _workDirector.Monitors, _previousMonitors, _notificationConditions, _notifications);
            _notificationDirector.Execute();
        }
コード例 #2
0
        /// <summary>
        /// 建構式
        /// </summary>
        /// <param name="detector">偵測器</param>
        /// <param name="record">接收記錄訊息</param>
        /// <param name="deviceType">設備類型</param>
        /// <param name="sourceIp">來源 IP</param>
        public GenericRecordDirector(Detector detector, string record, DeviceType deviceType, NotifierStrategy strategy, string sourceIp = null)
        {
            _license      = new LicenseBusinessLogic();
            _workDirector = new WorkDirector(detector, record, deviceType, sourceIp);

            _notificationDirector = new NotificationDirector(strategy);

            _pusher = new MonitorPushStrategy();
        }