Class: Circuits::Component::Nor
- Defined in:
- lib/circuits/component/nor.rb
Overview
Logical NOR Operator
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
-
#tick ⇒ Object
Sets the output to be the result of a logical OR of the inputs.
Methods inherited from Base
Constructor Details
This class inherits a constructor from Circuits::Component::Base
Instance Method Details
#tick ⇒ Object
Sets the output to be the result of a logical OR of the inputs
8 9 10 |
# File 'lib/circuits/component/nor.rb', line 8 def tick self[:out].set(!inputs.map(&:get).inject(:|)) end |