Class: MessageBird::SMS

Inherits:
Object
  • Object
show all
Extended by:
Helpers
Defined in:
lib/messagebird/sms.rb

Class Method Summary collapse

Methods included from Helpers

config, constantize, escape

Class Method Details

.deliver(originator, recipients, message, options = {}, &block) ⇒ Object



6
7
8
# File 'lib/messagebird/sms.rb', line 6

def deliver(originator, recipients, message, options={}, &block)
  new(originator, recipients, message, options, &block).deliver
end

.new(originator, recipients, message, options = {}, &block) ⇒ Object



10
11
12
13
# File 'lib/messagebird/sms.rb', line 10

def new(originator, recipients, message, options={}, &block)
  module_name = options.delete(:module) || config.module
  klass_for(module_name).new(originator, recipients, message, options, &block)
end