Return the HTML code for the table as a string.
(self)
| 228 | self.css_class = css_class |
| 229 | |
| 230 | def __str__(self): |
| 231 | """Return the HTML code for the table as a string.""" |
| 232 | table = [] |
| 233 | |
| 234 | if self.css_class: |
| 235 | table.append("<table class=%s>" % self.css_class) |
| 236 | else: |
| 237 | table.append("<table>") |
| 238 | |
| 239 | if self.header_row: |
| 240 | table.append(str(self.header_row)) |
| 241 | |
| 242 | for row in self.rows: |
| 243 | table.append(str(row)) |
| 244 | |
| 245 | table.append("</table>") |
| 246 | |
| 247 | return "\n".join(table) |
| 248 | |
| 249 | def __iter__(self): |
| 250 | """Iterate through table rows""" |
nothing calls this directly
no outgoing calls
no test coverage detected