Ejemplo n.º 1
0
        protected bool IsWriteAllowed()
        {
            State state   = this.CircuitState[this.write];
            bool  allowed = (state == this.writeOn && CircuitFunction.Not(state) == this.oldWriteState);

            this.oldWriteState = state;
            return(allowed);
        }
Ejemplo n.º 2
0
 private void StateChangedAction(CircuitSymbol symbol, bool isPressed)
 {
     if (isPressed)
     {
         if (this.isToggle)
         {
             this.SetState(CircuitFunction.Not(this.State));
             this.Invalid = true;
         }
         else
         {
             this.SetState(State.On1);
         }
     }
     else if (!this.isToggle)
     {
         this.SetState(State.On0);
     }
 }
Ejemplo n.º 3
0
 public override bool Evaluate()
 {
     return(this.SetResult0(CircuitFunction.Not(this.And())));
 }
Ejemplo n.º 4
0
 public override bool Evaluate()
 {
     return(this.SetResult0(CircuitFunction.Not(this.CircuitState[this.param0])));
 }