Class: PinkShirt::SAX::Tables
- Inherits:
-
Base
- Object
- Base
- PinkShirt::SAX::Tables
show all
- Defined in:
- lib/pink_shirt/sax/tables.rb
Constant Summary
collapse
- TAGS =
%w(table th tr td tbody thead)
Instance Method Summary
collapse
Methods inherited from Base
#add_attributes, #initialize, #method_missing, #to_s
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
in the class PinkShirt::SAX::Base
Instance Method Details
#end_table ⇒ Object
12
13
|
# File 'lib/pink_shirt/sax/tables.rb', line 12
def end_table
end
|
#end_tbody ⇒ Object
17
18
|
# File 'lib/pink_shirt/sax/tables.rb', line 17
def end_tbody
end
|
#end_td ⇒ Object
49
50
|
# File 'lib/pink_shirt/sax/tables.rb', line 49
def end_td
end
|
#end_th ⇒ Object
37
38
|
# File 'lib/pink_shirt/sax/tables.rb', line 37
def end_th
end
|
#end_thead ⇒ Object
23
24
|
# File 'lib/pink_shirt/sax/tables.rb', line 23
def end_thead
end
|
#end_tr ⇒ Object
29
30
31
|
# File 'lib/pink_shirt/sax/tables.rb', line 29
def end_tr
@output << "|\n"
end
|
#start_table(attrs) ⇒ Object
5
6
7
8
9
10
|
# File 'lib/pink_shirt/sax/tables.rb', line 5
def start_table attrs
@output << "\n"
@output << "table#{add_attributes(attrs)}.\n"
end
|
#start_tbody(attrs) ⇒ Object
14
15
|
# File 'lib/pink_shirt/sax/tables.rb', line 14
def start_tbody attrs
end
|
#start_td(attrs) ⇒ Object
| or |(someclass). , never |.
41
42
43
44
45
46
47
|
# File 'lib/pink_shirt/sax/tables.rb', line 41
def start_td attrs
if add_attributes(attrs)
@output << "|#{add_attributes(attrs)}. "
else
@output << "|"
end
end
|
#start_th(attrs) ⇒ Object
33
34
35
|
# File 'lib/pink_shirt/sax/tables.rb', line 33
def start_th attrs
@output << "|#{add_attributes(attrs)}_. "
end
|
#start_thead(attrs) ⇒ Object
20
21
|
# File 'lib/pink_shirt/sax/tables.rb', line 20
def start_thead attrs
end
|
#start_tr(attrs) ⇒ Object
26
27
|
# File 'lib/pink_shirt/sax/tables.rb', line 26
def start_tr attrs
end
|