Method: Infoboxer::Parser::HTML#html

Defined in:
lib/infoboxer/parser/html.rb

#htmlObject



8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# File 'lib/infoboxer/parser/html.rb', line 8

def html
  case
  when @context.check(%r{/[a-z]+>})
    html_closing_tag
  when @context.check(/br\s*>/)
    html_br
  when @context.check(%r{[a-z]+[^/>]*/>})
    html_auto_closing_tag
  when @context.check(%r{[a-z]+[^>/]*>})
    html_opening_tag
  else
    # not an HTML tag at all!
    nil
  end
end