Class: Sinatra::Twilio::Response
- Inherits:
-
Twilio::Response
- Object
- Twilio::Response
- Sinatra::Twilio::Response
- Defined in:
- lib/sinatra/twilio/response.rb
Instance Attribute Summary collapse
-
#target ⇒ Object
Returns the value of attribute target.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(target) ⇒ Response
constructor
A new instance of Response.
- #method_missing(method, *args, &block) ⇒ Object
Constructor Details
#initialize(target) ⇒ Response
Returns a new instance of Response.
8 9 10 11 |
# File 'lib/sinatra/twilio/response.rb', line 8 def initialize(target) super(nil) self.target = target end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(method, *args, &block) ⇒ Object
13 14 15 16 17 |
# File 'lib/sinatra/twilio/response.rb', line 13 def method_missing(method, *args, &block) target.send(method, *args, &block) rescue NoMethodError super(method, *args, &block) end |
Instance Attribute Details
#target ⇒ Object
Returns the value of attribute target.
6 7 8 |
# File 'lib/sinatra/twilio/response.rb', line 6 def target @target end |
Class Method Details
.allowed_verbs ⇒ Object
19 20 21 |
# File 'lib/sinatra/twilio/response.rb', line 19 def self.allowed_verbs superclass.allowed_verbs end |