Class: Signupto::Action::Sender

Inherits:
Base
  • Object
show all
Defined in:
lib/signupto/action/sender.rb

Instance Method Summary collapse

Methods inherited from Base

#to_s

Constructor Details

#initialize(account, message) ⇒ Sender

Returns a new instance of Sender.



5
6
7
8
9
10
11
12
13
14
15
# File 'lib/signupto/action/sender.rb', line 5

def initialize(, message)
  if message.is_a?(Message) and .is_a?(Account)
    if super(.apihash, .customer_number)
      @message = message
      payload = set_payload()
      run_action(payload, 'smpp_send')
    end
  else
    raise "You can only supply a Message object"
  end
end