Class: Twilio::TwilioObject

Inherits:
Object
  • Object
show all
Defined in:
lib/twilio/twilio_object.rb

Overview

:nodoc: all

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeTwilioObject

Returns a new instance of TwilioObject.



3
4
# File 'lib/twilio/twilio_object.rb', line 3

def initialize
end

Class Method Details

.method_missing(method_id, *args) ⇒ Object

:nodoc:



7
8
9
10
11
12
# File 'lib/twilio/twilio_object.rb', line 7

def method_missing(method_id, *args) #:nodoc:
  o = self.new
  o.send(method_id, *args)
rescue HTTParty::UnsupportedURIScheme
  raise "You must set Twilio.connect before calling #{self.inspect}##{method_id}"
end

Instance Method Details

#connected?Boolean

Returns:

  • (Boolean)


15
16
17
# File 'lib/twilio/twilio_object.rb', line 15

def connected?
  self.class.base_uri
end