class

Asciidoctor::AttributeList

Inherits Reference < Object

Handles parsing AsciiDoc attribute lists into a Hash of key/value pairs.

Constants

APOS = "'"
BACKSLASH = "\\"
BLANK_RX = /[ \t]+/
BOUNDARY_RX = {QUOT => /.*?[^\\](?=")/, APOS => /.*?[^\\](?=')/, "," => /.*?(?=[ \t]*(,|$))/}
ESCAPED_QUOTES = {QUOT => "\\\"", APOS => "\\'"}
NAME_RX = /[\p{L}\d_][\p{L}\d_-]*/
QUOT = "\""
SKIP_RX = {"," => /[ \t]*(,|$)/}

Constructors

new(source : String, block : AbstractBlock | Nil = nil, delimiter : String = ",")
Source

Class methods

rekey(attributes : Hash(String | Int32, String), positional_attrs : Array(String)) : Hash(String | Int32, String)
Source

Instance methods

parse(positional_attrs : Array(String) = [] of String) : Hash(String | Int32, String)
Source
parse_into(attributes : Hash(String | Int32, String), positional_attrs : Array(String) = [] of String) : Hash(String | Int32, String)
Source
rekey(positional_attrs : Array(String)) : Hash(String | Int32, String)
Source