Class: Qiita::Markdown::Filters::CustomBlock::Metadata
- Inherits:
-
Object
- Object
- Qiita::Markdown::Filters::CustomBlock::Metadata
- Defined in:
- lib/qiita/markdown/filters/custom_block.rb
Instance Attribute Summary collapse
-
#subtype ⇒ Object
readonly
Returns the value of attribute subtype.
-
#type ⇒ Object
readonly
Returns the value of attribute type.
Instance Method Summary collapse
-
#initialize(text) ⇒ Metadata
constructor
A new instance of Metadata.
Constructor Details
#initialize(text) ⇒ Metadata
Returns a new instance of Metadata.
21 22 23 24 |
# File 'lib/qiita/markdown/filters/custom_block.rb', line 21 def initialize(text) # Discared after the second word. @type, @subtype = text.split(" ") end |
Instance Attribute Details
#subtype ⇒ Object (readonly)
Returns the value of attribute subtype.
18 19 20 |
# File 'lib/qiita/markdown/filters/custom_block.rb', line 18 def subtype @subtype end |
#type ⇒ Object (readonly)
Returns the value of attribute type.
18 19 20 |
# File 'lib/qiita/markdown/filters/custom_block.rb', line 18 def type @type end |