Module: SmokeMonster::CoverMethods

Included in:
Cover
Defined in:
lib/smoke_monster/cover.rb

Instance Method Summary collapse

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(meth, *args, &blk) ⇒ Object



9
10
11
12
13
# File 'lib/smoke_monster/cover.rb', line 9

def method_missing(meth, *args, &blk)
  @subject.send(meth, *args, &blk)
rescue
  SmokeMonster::Cover.new Object.new
end

Instance Method Details

#initialize(subject) ⇒ Object



5
6
7
# File 'lib/smoke_monster/cover.rb', line 5

def initialize(subject)
  @subject = subject
end

#the_original_subjectObject



15
16
17
# File 'lib/smoke_monster/cover.rb', line 15

def the_original_subject
  @subject
end