class Asciidoctor::AbstractNode
def add_role name
Public: Adds the given role directly to this node.
def add_role name if (val = @attributes['role']) # NOTE center + include? is faster than split + include? if %( #{val} ).include? %( #{name} ) false else @attributes['role'] = %(#{val} #{name}) true end else @attributes['role'] = name true end end