Class: StrongConcerns::Intermediate

Inherits:
Object
  • Object
show all
Extended by:
Forwardable
Defined in:
lib/strong_concerns.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(subject, options) ⇒ Intermediate

Returns a new instance of Intermediate.



9
10
11
12
# File 'lib/strong_concerns.rb', line 9

def initialize(subject, options)
  @__subject = subject
  @options = options
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(meth) ⇒ Object

Raises:

  • (NameError)


14
15
16
# File 'lib/strong_concerns.rb', line 14

def method_missing(meth)
  raise NameError.new("Looks like you not list method <#{meth}> in self.require_methods of concern or misspelled it")
end

Instance Attribute Details

#optionsObject

Returns the value of attribute options.



7
8
9
# File 'lib/strong_concerns.rb', line 7

def options
  @options
end

Instance Method Details

#inspectObject



18
19
20
# File 'lib/strong_concerns.rb', line 18

def inspect
  "Intermediate<#{self.methods}>"
end