## helma.Html.TableWriter

    Object
       |
       +--helma.Html.TableWriter

This class provides various methods for programmatically creating an x/html table.
Defined in Html.js

SUMMARY: Constructor | Properties | Methods | DETAIL: Constructor | Properties | Methods

Constructor Summary
`helma.Html.TableWriter(<Number> numberOfColumns, <Object> attr)` Creates a new TableWriter instance

Properties Summary
`Boolean` | `writeHeader` If set to true the first row of the table data is rendered using `<th>` tags (defaults to false).
`Boolean` | `writeString` If set to true the TableWriter returns the rendered table as string, otherwise the table is written directly to response, which is the default.

Methods Summary
`String` | `close()` Closes all open table tags.
`void` | `write(<String> text, <Object> attr)` Writes a single table cell to response.

Constructor Detail

### helma.Html.TableWriter

    helma.Html.TableWriter(<Number> numberOfColumns, <Object> attr)

Creates a new TableWriter instance

Parameters:

`numberOfColumns` - The number of columns in the table

`attr` - An object containing attributes to use when rendering the single table elements. For a description see table.

Returns:

An instance of TableWriter

Properties Detail

### writeHeader

    Boolean writeHeader

If set to true the first row of the table data is rendered using `<th>` tags (defaults to false).

### writeString

    Boolean writeString

If set to true the TableWriter returns the rendered table as string, otherwise the table is written directly to response, which is the default.

Method Detail

### close

    String close()

Closes all open table tags. If writeString is set to true, this method returns the rendered table.

Returns:

The rendered table, if writeString is set to true, otherwise void.

### write

    void write(<String> text, <Object> attr)

Writes a single table cell to response.

Parameters:

`text` - The content of the table cess

`attr` - An optional object containig attributes to render for this table cell

SUMMARY: Constructor | Properties | Methods | DETAIL: Constructor | Properties | Methods

Documentation generated by JSDoc on Thu Apr 5 01:59:00 2007