Class: Line::Bot::MessageBuilder::Message::Text
- Inherits:
-
Line::Bot::MessageBuilder::Message
- Object
- Base
- Line::Bot::MessageBuilder::Message
- Line::Bot::MessageBuilder::Message::Text
- Defined in:
- lib/line/bot/message_builder/messages/text.rb
Instance Attribute Summary collapse
-
#text ⇒ Object
Returns the value of attribute text.
Attributes inherited from Base
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(text: nil) ⇒ Text
constructor
A new instance of Text.
Methods inherited from Base
Constructor Details
#initialize(text: nil) ⇒ Text
7 8 9 10 11 12 |
# File 'lib/line/bot/message_builder/messages/text.rb', line 7 def initialize(text: nil) super 'text' do @text = text yield self if block_given? end end |
Instance Attribute Details
#text ⇒ Object
Returns the value of attribute text.
5 6 7 |
# File 'lib/line/bot/message_builder/messages/text.rb', line 5 def text @text end |
Class Method Details
.required ⇒ Object
14 15 16 17 18 19 |
# File 'lib/line/bot/message_builder/messages/text.rb', line 14 def self.required { 'type' => String, 'text' => String } end |