Class: Coradoc::Element::Admonition
- Defined in:
- lib/coradoc/element/admonition.rb
Instance Attribute Summary collapse
-
#content ⇒ Object
Returns the value of attribute content.
-
#line_break ⇒ Object
Returns the value of attribute line_break.
-
#type ⇒ Object
Returns the value of attribute type.
Instance Method Summary collapse
-
#initialize(content, type, options = {}) ⇒ Admonition
constructor
A new instance of Admonition.
- #to_adoc ⇒ Object
Methods inherited from Base
#children_accessors, children_accessors, declare_children, #simplify_block_content, visit, #visit
Constructor Details
#initialize(content, type, options = {}) ⇒ Admonition
Returns a new instance of Admonition.
6 7 8 9 10 |
# File 'lib/coradoc/element/admonition.rb', line 6 def initialize(content, type, = {}) @content = content @type = type.downcase.to_sym @line_break = .fetch(:line_break, "") end |
Instance Attribute Details
#content ⇒ Object
Returns the value of attribute content.
4 5 6 |
# File 'lib/coradoc/element/admonition.rb', line 4 def content @content end |
#line_break ⇒ Object
Returns the value of attribute line_break.
4 5 6 |
# File 'lib/coradoc/element/admonition.rb', line 4 def line_break @line_break end |
#type ⇒ Object
Returns the value of attribute type.
4 5 6 |
# File 'lib/coradoc/element/admonition.rb', line 4 def type @type end |