Class: Asciidoctor::ISO::TermLookupCleanup
- Inherits:
-
Object
- Object
- Asciidoctor::ISO::TermLookupCleanup
- Defined in:
- lib/asciidoctor/iso/term_lookup_cleanup.rb
Overview
Intelligent term lookup xml modifier Lookup all ‘term` and `calause` tags and replace `termxref` tags with `xref`:target tag
Constant Summary collapse
- AUTOMATIC_GENERATED_ID_REGEXP =
/\A_/
- EXISTING_TERM_REGEXP =
/\Aterm-/
Instance Attribute Summary collapse
-
#log ⇒ Object
readonly
Returns the value of attribute log.
-
#termlookup ⇒ Object
readonly
Returns the value of attribute termlookup.
-
#xmldoc ⇒ Object
readonly
Returns the value of attribute xmldoc.
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(xmldoc, log) ⇒ TermLookupCleanup
constructor
A new instance of TermLookupCleanup.
Constructor Details
#initialize(xmldoc, log) ⇒ TermLookupCleanup
Returns a new instance of TermLookupCleanup.
14 15 16 17 18 |
# File 'lib/asciidoctor/iso/term_lookup_cleanup.rb', line 14 def initialize(xmldoc, log) @xmldoc = xmldoc @log = log @termlookup = {} end |
Instance Attribute Details
#log ⇒ Object (readonly)
Returns the value of attribute log.
12 13 14 |
# File 'lib/asciidoctor/iso/term_lookup_cleanup.rb', line 12 def log @log end |
#termlookup ⇒ Object (readonly)
Returns the value of attribute termlookup.
12 13 14 |
# File 'lib/asciidoctor/iso/term_lookup_cleanup.rb', line 12 def termlookup @termlookup end |
#xmldoc ⇒ Object (readonly)
Returns the value of attribute xmldoc.
12 13 14 |
# File 'lib/asciidoctor/iso/term_lookup_cleanup.rb', line 12 def xmldoc @xmldoc end |
Instance Method Details
#call ⇒ Object
20 21 22 23 |
# File 'lib/asciidoctor/iso/term_lookup_cleanup.rb', line 20 def call @termlookup = replace_automatic_generated_ids_terms end |