Class: Bot::Message::Photo
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
-
#initialize(to, photo_url, suggested_responses = false, options = {}) ⇒ Photo
constructor
A new instance of Photo.
Methods inherited from Base
Constructor Details
#initialize(to, photo_url, suggested_responses = false, options = {}) ⇒ Photo
Returns a new instance of Photo.
4 5 6 7 8 9 10 11 12 13 14 |
# File 'lib/bot/messages/photo.rb', line 4 def initialize(to, photo_url, suggested_responses=false, ={}) self. = { 'type' => 'gallery', 'to' => to, 'picUrl' => photo_url, 'typeTime' => 0, }.merge() self.['chatId'] = ['chatId'] if ['chatId'] self.suggested_responses = suggested_responses end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Bot::Message::Base