Class: Factbase::Nil
Overview
It evaluates to true if the value is nil.
Instance Method Summary collapse
-
#evaluate(fact, maps, fb) ⇒ Boolean
Evaluate term on a fact.
-
#initialize(operands) ⇒ Nil
constructor
Constructor.
Methods included from TermShared
Constructor Details
#initialize(operands) ⇒ Nil
Constructor.
12 13 14 15 |
# File 'lib/factbase/terms/nil.rb', line 12 def initialize(operands) super() @operands = operands end |
Instance Method Details
#evaluate(fact, maps, fb) ⇒ Boolean
Evaluate term on a fact.
22 23 24 25 |
# File 'lib/factbase/terms/nil.rb', line 22 def evaluate(fact, maps, fb) assert_args(1) _values(0, fact, maps, fb).nil? end |