Class: Asciidoctor::Extensions::MacroProcessor
- Defined in:
- lib/asciidoctor/extensions.rb
Direct Known Subclasses
Instance Attribute Summary collapse
Attributes inherited from Processor
Instance Method Summary collapse
-
#initialize(name = nil, config = {}) ⇒ MacroProcessor
constructor
A new instance of MacroProcessor.
- #process(parent, target, attributes) ⇒ Object
Methods inherited from Processor
config, #create_block, #create_image_block, #create_inline, #create_list, #create_list_item, #create_section, enable_dsl, option, #parse_attributes, #parse_content, #update_config
Constructor Details
#initialize(name = nil, config = {}) ⇒ MacroProcessor
Returns a new instance of MacroProcessor.
568 569 570 571 572 |
# File 'lib/asciidoctor/extensions.rb', line 568 def initialize name = nil, config = {} super config @name = name || @config[:name] @config[:content_model] ||= :attributes end |
Instance Attribute Details
#name ⇒ Object
566 567 568 |
# File 'lib/asciidoctor/extensions.rb', line 566 def name @name end |
Instance Method Details
#process(parent, target, attributes) ⇒ Object
574 575 576 |
# File 'lib/asciidoctor/extensions.rb', line 574 def process parent, target, attributes raise ::NotImplementedError, %(#{MacroProcessor} subclass #{self.class} must implement the ##{__method__} method) end |