|
Components |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
com.sas.servlet.tbeans.remotefileselector2.html.ColumnAsRowCellRenderer
public class ColumnAsRowCellRenderer
ColumnAsRowCellRenderer
is a class that constructs
a TableCellRenderer
which
writes out the last column in a
TableView
as a row.
This renderer is used to render the Description column as a row in
the RemoteFileSelector
transformation bean.
This cell renderer specifically ends the previous row with a </tr>,
starts a new row with a <tr>, and sets the style class to match the previous row.
The data rendered in this row is associated with the previous row.
This renderer can be used with instances of the
TableView
component.
Field Summary |
---|
Fields inherited from interface com.sas.servlet.tbeans.HttpConstants |
---|
ALL, BASELINE, CHAR, COL, COLGROUP, JUSTIFY, MULTIPLE, NONE, ROW, ROWGROUP, SINGLE |
Constructor Summary | |
---|---|
ColumnAsRowCellRenderer()
Constructs a new ColumnAsRowCellRenderer. |
Method Summary | |
---|---|
protected int |
getDescriptionCount()
Returns the current description count. |
protected void |
setDescriptionCount(int count)
Sets the number appended to the renderer name to generate an id for the <td> tag containing a description or some data. |
void |
write(java.io.PrintWriter out,
AbstractBaseTableView tableview,
java.lang.Object value,
java.lang.String name,
ActionList actions)
Renders the last column in a TableView as a row. |
Methods inherited from class com.sas.servlet.tbeans.remotefileselector2.BaseFieldRenderer |
---|
getArrayName, getName, getStartColumn, isFieldRenderable, isVisible, setArrayName, setFieldRenderable, setName, setStartColumn, setVisible |
Methods inherited from class com.sas.servlet.tbeans.tableview.html.DefaultTableCellRenderer |
---|
getTableCellContentsRenderer, setTableCellContentsRenderer |
Methods inherited from class com.sas.servlet.tbeans.tableview.html.BaseTableCell |
---|
getBgColor, getColSpan, getCustomAttributes, getHeaders, getHeight, getHeightPercentage, getHorizontalAlignment, getId, getLocale, getRowSpan, getScope, getStyleInfo, getVerticalAlignment, getWidth, getWidthPercentage, isHeader, isNoWrap, setBgColor, setColSpan, setCustomAttributes, setHeader, setHeaders, setHeight, setHeightPercentage, setHorizontalAlignment, setId, setLocale, setNoWrap, setRowSpan, setScope, setStyleInfo, setVerticalAlignment, setWidth, setWidthPercentage, writeBeginCell, writeEndCell |
Methods inherited from interface com.sas.servlet.tbeans.tableview.TableCellRenderer |
---|
getLocale, setLocale |
Methods inherited from interface com.sas.servlet.tbeans.tableview.TableCell |
---|
isHeader, setHeader, writeBeginCell, writeEndCell |
Constructor Detail |
---|
public ColumnAsRowCellRenderer()
Method Detail |
---|
protected void setDescriptionCount(int count)
count
- description identifiergetDescriptionCount()
protected int getDescriptionCount()
JavaScript
uses the table cells in the array to obtain the parent
<tr> tags. The table row style is set to block
to show the descriptions or to none
to
hide the descriptions.
setDescriptionCount(int)
public void write(java.io.PrintWriter out, AbstractBaseTableView tableview, java.lang.Object value, java.lang.String name, ActionList actions) throws java.io.IOException
Renders the last column in a TableView
as a row.
JavaScript
is also generated to save the description
values in an array so that the value can
be hidden or displayed based on the selection
of the Show Description CheckBox
component.
If isFieldRenderable()
returns false then nothing
is rendered or written out for the value
.
This prevents the display of unused code in the
case where the description row is never displayed.
If isFieldRenderable()
returns true
then if
a description exists it is renderered along
with the necessary JavaScript
for storing
the description value.
If isVisible() returns false the descrption is
rendered with a display style of none
.
Therefore, the description is hidden.
If isVisible() returns true the description
is rendered with a display style of block
.
Therefore, the description is visible.
write
in interface TableCell
write
in class DefaultTableCellRenderer
out
- the output streamtableview
- the instance of the tableview being writtenvalue
- the value to display as the cell's contentsname
- the name to use for the contents componentactions
- an actionlist of all the valid actions for this cell
java.io.IOException
- Thrown if some type of I/O error occurs
|
Components |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |