Class: Mobilove::Text
- Inherits:
-
Object
- Object
- Mobilove::Text
- Defined in:
- lib/mobilove/text.rb
Instance Method Summary collapse
- #flash_message(to, message, options = {}) ⇒ Object
-
#initialize(key, route, from) ⇒ Text
constructor
A new instance of Text.
- #send_message(to, message, options = {}) ⇒ Object
Constructor Details
#initialize(key, route, from) ⇒ Text
Returns a new instance of Text.
7 8 9 |
# File 'lib/mobilove/text.rb', line 7 def initialize(key, route, from) @key, @route, @from = key, route, from end |
Instance Method Details
#flash_message(to, message, options = {}) ⇒ Object
17 18 19 |
# File 'lib/mobilove/text.rb', line 17 def (to, , ={}) (to, , { :type => "flash" }.merge()) end |
#send_message(to, message, options = {}) ⇒ Object
11 12 13 14 15 |
# File 'lib/mobilove/text.rb', line 11 def (to, , ={}) url = prepare_url(to, , ) response = RestClient.get(url) respond(response) end |