Class: Slackened::BlockKit::Builder
- Inherits:
-
Object
- Object
- Slackened::BlockKit::Builder
- Defined in:
- lib/slackened/block_kit/builder.rb
Overview
where the blocks are stored
Instance Attribute Summary collapse
-
#blocks ⇒ Object
Returns the value of attribute blocks.
Instance Method Summary collapse
-
#initialize ⇒ Builder
constructor
A new instance of Builder.
- #row(row) ⇒ Object
- #setup! ⇒ Object
Constructor Details
#initialize ⇒ Builder
Returns a new instance of Builder.
9 10 11 |
# File 'lib/slackened/block_kit/builder.rb', line 9 def initialize setup! end |
Instance Attribute Details
#blocks ⇒ Object
Returns the value of attribute blocks.
7 8 9 |
# File 'lib/slackened/block_kit/builder.rb', line 7 def blocks @blocks end |
Instance Method Details
#row(row) ⇒ Object
13 14 15 |
# File 'lib/slackened/block_kit/builder.rb', line 13 def row(row) blocks.push(row) end |
#setup! ⇒ Object
17 18 19 |
# File 'lib/slackened/block_kit/builder.rb', line 17 def setup! @blocks = [] end |