Exemple #1
0
        public override void Evaluate <T>(
            ICircuitEvaluator <T> evaluator,
            EvaluationState <T> evaluationState)
        {
            T value = evaluator.EvaluateXorGate(
                evaluationState.GetGateEvaluationValue(_leftInputGate),
                evaluationState.GetGateEvaluationValue(_rightInputGate)
                );

            evaluationState.SetGateEvaluationValue(this, value);
        }
Exemple #2
0
 public T EvaluateXorGate(T leftValue, T rightValue)
 {
     return(_innerEvaluator.EvaluateXorGate(leftValue, rightValue));
 }
Exemple #3
0
 public T EvaluateXorGate(T leftValue, T rightValue, GateContext gateContext, CircuitContext circuitContext)
 {
     return(_innerEvaluator.EvaluateXorGate(leftValue, rightValue, gateContext, circuitContext));
 }
Exemple #4
0
 public Task <T> EvaluateXorGate(Task <T> leftValue, Task <T> rightValue, GateContext gateContext, CircuitContext circuitContext)
 {
     return(Task.WhenAll(leftValue, rightValue).ContinueWith(
                task => _innerEvaluator.EvaluateXorGate(task.Result[0], task.Result[1], gateContext, circuitContext)
                ));
 }