Class: HTML5::InRowPhase
- Inherits:
-
Phase
- Object
- Phase
- HTML5::InRowPhase
show all
- Defined in:
- lib/html5/html5parser/in_row_phase.rb
Instance Method Summary
collapse
Methods inherited from Phase
#adjust_foreign_attributes, #adjust_mathml_attributes, #assert, end_tag_handlers, handle_end, handle_start, #in_scope?, #initialize, #processComment, #processDoctype, #processEndTag, #processStartTag, #remove_open_elements_until, #startTagHtml, start_tag_handlers, tag_handlers
Constructor Details
This class inherits a constructor from HTML5::Phase
Instance Method Details
#endTagIgnore(name) ⇒ Object
68
69
70
71
|
# File 'lib/html5/html5parser/in_row_phase.rb', line 68
def endTagIgnore(name)
parse_error("unexpected-end-tag-in-table-row",
{"name" => name})
end
|
#endTagOther(name) ⇒ Object
73
74
75
|
# File 'lib/html5/html5parser/in_row_phase.rb', line 73
def endTagOther(name)
@parser.phases[:inTable].processEndTag(name)
end
|
#endTagTable(name) ⇒ Object
50
51
52
53
54
55
56
|
# File 'lib/html5/html5parser/in_row_phase.rb', line 50
def endTagTable(name)
ignoreEndTag = ignoreEndTagTr
endTagTr('tr')
@parser.phase.processEndTag(name) unless ignoreEndTag
end
|
#endTagTableRowGroup(name) ⇒ Object
58
59
60
61
62
63
64
65
66
|
# File 'lib/html5/html5parser/in_row_phase.rb', line 58
def endTagTableRowGroup(name)
if in_scope?(name, true)
endTagTr('tr')
@parser.phase.processEndTag(name)
else
parse_error "unexpected-end-tag", {:name => name}
end
end
|
#endTagTr(name) ⇒ Object
38
39
40
41
42
43
44
45
46
47
48
|
# File 'lib/html5/html5parser/in_row_phase.rb', line 38
def endTagTr(name)
if ignoreEndTagTr
assert @parser.inner_html
parse_error "unexpected-end-tag", {:name => name}
else
clearStackToTableRowContext
@tree.open_elements.pop
@parser.phase = @parser.phases[:inTableBody]
end
end
|
#process_eof ⇒ Object
77
78
79
|
# File 'lib/html5/html5parser/in_row_phase.rb', line 77
def process_eof
@parser.phases[:inTable].process_eof
end
|
#processCharacters(data) ⇒ Object
12
13
14
|
# File 'lib/html5/html5parser/in_row_phase.rb', line 12
def processCharacters(data)
@parser.phases[:inTable].processCharacters(data)
end
|
#processSpaceCharacters(data) ⇒ Object
16
17
18
|
# File 'lib/html5/html5parser/in_row_phase.rb', line 16
def processSpaceCharacters(data)
@parser.phases[:inTable].processSpaceCharacters(data)
end
|
#startTagOther(name, attributes) ⇒ Object
34
35
36
|
# File 'lib/html5/html5parser/in_row_phase.rb', line 34
def startTagOther(name, attributes)
@parser.phases[:inTable].processStartTag(name, attributes)
end
|
#startTagTableCell(name, attributes) ⇒ Object
20
21
22
23
24
25
|
# File 'lib/html5/html5parser/in_row_phase.rb', line 20
def startTagTableCell(name, attributes)
clearStackToTableRowContext
@tree.insert_element(name, attributes)
@parser.phase = @parser.phases[:inCell]
@tree.activeFormattingElements.push(Marker)
end
|
#startTagTableOther(name, attributes) ⇒ Object
27
28
29
30
31
32
|
# File 'lib/html5/html5parser/in_row_phase.rb', line 27
def startTagTableOther(name, attributes)
ignoreEndTag = ignoreEndTagTr
endTagTr('tr')
@parser.phase.processStartTag(name, attributes) unless ignoreEndTag
end
|