Class | Asciidoctor::Block |
In: |
lib/asciidoctor/block.rb
|
Parent: | AbstractBlock |
Public: Methods for managing blocks of Asciidoc content in a section.
Examples
block = Asciidoctor::Block.new(document, :paragraph, ["`This` is a <test>"]) block.content => ["<em>This</em> is a <test>"]
context | -> | blockname |
Public: Create alias for context to be consistent w/ AsciiDoc |
buffer | [RW] | Public: Get/Set the original Array content for this section block. |
Public: Initialize an Asciidoctor::Block object.
parent - The parent Asciidoc Object. context - The Symbol context name for the type of content. buffer - The Array buffer of source data (default: nil).
Public: Get an HTML-ified version of the source buffer, with special Asciidoc characters and entities converted to their HTML equivalents.
Examples
doc = Asciidoctor::Document.new block = Asciidoctor::Block.new(doc, :paragraph, ['`This` is what happens when you <meet> a stranger in the <alps>!']) block.content => ["<em>This</em> is what happens when you <meet> a stranger in the <alps>!"]