示例#1
0
        public static void Main()
        {
            IRequestKeyCard keyCardCheck = new KeyCardCheck();
            IRequestPinCode pinCodeCheck = new PinCodeCheck();
            SecurityManager manager      = new SecurityManager(keyCardCheck, pinCodeCheck);

            manager.Check();
        }
        public static void Main()
        {
            ScannerUI       scannerUi    = new ScannerUI();
            KeyCardCheck    keyCardCheck = new KeyCardCheck(scannerUi);
            PinCodeCheck    pinCodeCheck = new PinCodeCheck(scannerUi);
            SecurityManager manager      = new SecurityManager(keyCardCheck, pinCodeCheck);

            manager.Check();
        }
 public SecurityManager(KeyCardCheck keyCardCheck, PinCodeCheck pinCodeCheck)
 {
     this.keyCardCheck = keyCardCheck;
     this.pinCodeCheck = pinCodeCheck;
 }