Class: Naught::NullClassBuilder::Commands::PredicatesReturn

Inherits:
Naught::NullClassBuilder::Command show all
Defined in:
lib/naught/null_class_builder/commands/predicates_return.rb

Instance Attribute Summary

Attributes inherited from Naught::NullClassBuilder::Command

#builder

Instance Method Summary collapse

Methods inherited from Naught::NullClassBuilder::Command

#defer

Constructor Details

#initialize(builder, return_value) ⇒ PredicatesReturn

Returns a new instance of PredicatesReturn.



7
8
9
10
# File 'lib/naught/null_class_builder/commands/predicates_return.rb', line 7

def initialize(builder, return_value)
  super(builder)
  @predicate_return_value = return_value
end

Instance Method Details

#callObject



12
13
14
15
16
17
# File 'lib/naught/null_class_builder/commands/predicates_return.rb', line 12

def call
  defer do |subject|
    define_method_missing(subject)
    define_predicate_methods(subject)
  end
end