Beispiel #1
0
        public IBiometricSystem <TInputData> createFromBlockType <InputBlockType>() where InputBlockType : Core.Block.IInputDataProcessingBlock <TInputData>, new()
        {
            InputBlockType block = new InputBlockType();
            BiometricSystemSettings <TInputData> settings = new  BiometricSystemSettings <TInputData>(block);

            return(new BiometricSystem <TInputData>(settings));
        }
Beispiel #2
0
 public void SetBlockInput(bool block, InputBlockType blockType)
 {
     if (NetworkController.IsClient())
     {
         return;
     }
     BlockType = block ? blockType : (InputBlockType?)null;
     binding.CallFieldsOfType <InputBlocker>(field => field.SetBlocked(block), field => IsEventBlocked(field, blockType));
 }
Beispiel #3
0
        private bool IsEventBlocked(FieldInfo field, InputBlockType blockType)
        {
            NotBlocked blockedAttribute = field.GetCustomAttribute <NotBlocked>();

            return(blockedAttribute == null || blockedAttribute.NotBlockedTypes.Count > 0 && !blockedAttribute.NotBlockedTypes.Contains(blockType));
        }