Beispiel #1
0
        public NotGate Build()
        {
            var gate = new NotGate();

            gate.SetInput(_input);

            return(gate);
        }
Beispiel #2
0
        //  can be removed; just trying out stuff
        public void BasicComposite_NoBuilders()
        {
            var notGate = new NotGate();

            notGate.SetInput(Generator.AnInactiveSignal());

            var orGate = new OrGate();

            orGate.AddInput(Generator.AnInactiveSignal());
            orGate.AddInput(Generator.AnActiveSignal());

            var andGate = new AndGate();

            andGate.AddInput(notGate);
            andGate.AddInput(orGate);

            Assert.True(andGate.Output());
        }