|
Components |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
com.sas.servlet.tbeans.tableview.BaseTableView
public abstract class BaseTableView
The base abstract Transformation Bean for creating a 2-dimensional Table. The BaseTableView Transformation Bean requires a model that implements javax.swing.table.TableModel.
The TableColumn provides a slot for holding an identifier or "tag" for each column, and the TableView and TableColumnModel both support getColumn(Object id) conveniences for locating columns by their identifier. If no identifier is explicitly set, the TableColumn returns its header value (the name of the column) as a default. A different identifier, which can be of any type, can be set using the TableColumn's setIdentifier method. All of the TableView's functions operate correctly regardless of the type and uniqueness of these identifiers. To specify a custom column (i.e. a column that is not in the TableModel), set the TableColumn's modelIndex to -1.
Note that subclasses of this bean actually provide the markup rendering used in/with Servlet and JavaServer Pages technologies. If you need to add support for a markup language that is not explicitly provided with AppDev Studio, then you must extend this class.
For More Information:
JSP custom tags provide an alternative to using the TransformationBeans. Visit the Custom Tag Library Reference for additional information on these custom tags.
Note: A snapshot of the AppDev Studio Developers Site is installed on your local Web server when you install AppDev Studio. To access the site from webAF, select Help -> Developer Site .
Field Summary | |
---|---|
protected java.lang.String[] |
columnsToExportAsTextIfCustomFormatted
|
protected java.lang.String[] |
columnsToNotEncode
|
static int |
EDITROW
Used to specify the row being written when the action for the EDIT_ROW_AREA are being rendered. |
static int |
LASTROW
Used to specify the LASTROW when setting the CellRenderers and CellEditors. |
Fields inherited from class com.sas.servlet.tbeans.tableview.AbstractBaseTableView |
---|
DEFAULT_EXPORT_NUMERIC_CUSTOM_FORMATED_VALUES_AS_TEXT, MISSING_STYLEINFO, WRAP_ALL, WRAP_NONE, WRAP_PER_COLUMN |
Fields inherited from interface com.sas.servlet.tbeans.tableview.ExportAsHyperlinkInterface |
---|
DEFAULT_VALUE_FOR_CURRENT_VALUE_TO_ENCODE |
Fields inherited from interface com.sas.servlet.tbeans.HttpConstants |
---|
ALL, BASELINE, CHAR, COL, COLGROUP, JUSTIFY, MULTIPLE, NONE, ROW, ROWGROUP, SINGLE |
Constructor Summary | |
---|---|
BaseTableView()
Constructs a new default TableView with a null data model, a null column model and a null row model. |
Method Summary | |
---|---|
void |
addColumn(TableColumn column)
Convenience method to add the column to the column model. |
void |
cancel()
Cancel any editing changes. |
void |
cleanUpResources()
This method releases all of the necessary resources that were needed by the transformation bean to render itself. |
void |
columnAdded(TableColumnModelEvent event)
Invoked when a column is added to the table column model. |
void |
columnMoved(TableColumnModelEvent event)
Invoked when a column is moved in the table column model. |
void |
columnRemoved(TableColumnModelEvent event)
Invoked when a column is removed from the table column model. |
void |
commit()
Commit any editing changes. |
void |
createDefaultColumnsFromModel()
Creates default columns for the table from the data model using the getColumnCount method defined in the TableModel interface. |
void |
delete(int row)
Delete the given row. |
boolean |
getAutoCreateColumnsFromModel()
Determines whether the table will create default columns from the model. |
TableCellEditor |
getCellEditor(int row,
int column)
Returns an appropriate editor for the cell specified by this row and column. |
TableCellRenderer |
getCellRenderer(int row,
int column)
Returns an appropriate renderer for the cell specified by this row and column. |
TableColumn |
getColumn(java.lang.Object identifier)
Convenience method to get the column from the column model. |
int |
getColumnCount()
Convenience method to return the number of columns in the column model. |
BaseColumnHeader |
getColumnHeader()
Returns the columnHeader for the TableView. |
protected ActionList |
getColumnHeaderActions(TableColumn column,
java.lang.String header)
Returns the ActionList to be rendered as the column header for the given column. |
com.sas.servlet.tbeans.tableview.ColumnHeaderAreaRenderer |
getColumnHeaderAreaRenderer()
|
TableColumnModel |
getColumnModel()
Returns the column model that contains all the column information for the TableView. |
int |
getColumnScrollSize()
Return the number of columns to scroll when paging forward/backward. |
protected java.lang.String[] |
getColumnsToExportAsTextIfCustomFormatted(com.sas.iquery.metadata.business.DataItem[] dataItems)
|
protected java.lang.String |
getColumnUniqueModelId(int colModelIndex)
|
int |
getCurrentColumn()
Returns the column number of the current column being displayed in the TableView or -1 if no columns have been displayed yet. |
int |
getCurrentRow()
Returns the row number of the current row being displayed in the TableView or -1 if no rows have been displayed yet. |
protected ActionList |
getDataCellActions(int rowNumber,
int colModelIndex)
Returns the ActionList to be rendered as the cell for the given row and column coordinates. |
abstract BaseColumnHeader |
getDefaultColumnHeader()
Returns the default columnHeader for the TableView. |
abstract TableRowRenderer |
getDefaultColumnHeaderRowRenderer()
Gets the default row renderer for the TableView's ColumnHeader row. |
abstract TableColumnModel |
getDefaultColumnModel()
Returns the default column model for the TableView. |
abstract TableColumn |
getDefaultEditColumn()
Returns the default instance of TableColumn to use as the column, independent of the data, which contains the edit actions. |
abstract HttpEditController |
getDefaultEditController()
Returns the default edit controller. |
abstract TableCellEditor |
getDefaultEditor()
Gets the default cell editor for the TableView. |
abstract TableCellContentsRenderer |
getDefaultNoRowsRenderer()
Gets the default cell content renderer to use for the TableView when there are no rows in the TableView or the model is not set. |
abstract TableCellRenderer |
getDefaultRenderer()
Gets the default cell renderer for the TableView. |
abstract BaseRowHeader |
getDefaultRowHeader()
Returns the default rowHeader for the TableView. |
abstract TableRowModel |
getDefaultRowModel()
Returns the default row model for the TableView. |
abstract TableRowRenderer |
getDefaultRowRenderer()
Gets the default row renderer for the TableView's data rows. |
abstract TableColumn |
getDefaultRowSelectionColumn()
Returns the default instance of TableColumn to use as the column, independent of the data, that can be used to select rows in the TableView. |
TableColumn |
getEditColumn()
Returns an instance of TableColumn to use as the column, independent of the data, which contains the edit actions. |
protected ActionList |
getEditColumnActions(int rowNumber)
Returns the ActionList of edit actions for the given row. |
HttpEditController |
getEditController()
Returns the controller class used to assist in editing the table. |
protected ActionList |
getEditRowActions()
Returns the ActionList of edit actions for the EDITROW. |
javax.swing.table.TableModel |
getModel()
Return the data model for the TableView. |
protected int |
getMultiColumnRuleCount()
|
TableCellContentsRenderer |
getNoRowsRenderer()
Gets the cell content renderer to use for the TableView when there are no rows in the TableView or the model is not set. |
int |
getRowCount()
Convenience method to return the number of rows available from the model or -1 if the model is not set. |
BaseRowHeader |
getRowHeader()
Returns the rowHeader for the TableView. |
TableRowModel |
getRowModel()
Returns the row model that contains all the row renderers for the TableView. |
TableRowRenderer |
getRowRenderer(int row)
Returns an appropriate renderer for the row specified by this row. |
TableColumn |
getRowSelectionColumn()
Returns the instance of TableColumn used to represent a column, independent of the data, that can be used to select rows in the TableView. |
java.util.Map |
getRowsToDelete()
Gets the map containing the name/value pairs of the rows selected for deletion. |
java.util.Map |
getUncommittedValues()
Gets the map containing the name/value pairs of the editable fields that have changed and need to be committed. |
void |
gotoRow(int row)
Navigates to the given row. |
void |
initialize()
Initializes the TableView Object. |
void |
initializeColumnNumbers()
Initializes the column numbers. |
void |
initializeRowNumbers()
Initializes the row numbers. |
void |
insert(int row)
Insert a row before the given row. |
boolean |
isAccurateRowCountAvailable()
Returns true if the actual row count is known. |
boolean |
isAutoCommit()
Determines whether changed values are committed automatically or the user is prompted to commit the changes. |
boolean |
isCancelSupported()
Determines whether canceling an edit change is supported. |
boolean |
isCellIdsGenerated()
Returns true if the TableView's cells should have an id property generated. |
boolean |
isColumnMoveAllowed(int columnIndex,
int newIndex)
Check to see if the column at columnIndex can be moved to newIndex. |
boolean |
isCommitSupported()
Determines whether commiting values is supported. |
boolean |
isCurrentValueToEncode()
|
boolean |
isDeleteSupported()
Determines whether deleting a row is supported. |
boolean |
isExportNumericCustomFormattedValuesAsText(int colModelIndex)
Returns true if, for a specific column, numeric custom formatted values should be exported as text to Excel, false otherwise. |
boolean |
isGotoColumnSupported()
Determines whether navigation to any given column is supported. |
boolean |
isGotoRowSupported()
Determines whether navigation to any given row is supported. |
boolean |
isInsertSupported()
Determines whether inserting a row is supported. |
boolean |
isPromptOnDelete()
Determines whether to prompt the user when deleting a row. |
boolean |
isUpdateSupported()
Determines whether updating a row is supported. |
void |
lastRow()
Navigates to the last row. |
void |
moveColumn(int column,
int targetColumn)
Convenience method to move a column in the column model. |
void |
removeColumn(TableColumn column)
Convenience method to remove a column from the column model. |
protected void |
resetColumnHeaderActions()
Called after the actions from getColumnHeaderActions have been rendered to clear out the ActionList for the columnHeaderActions. |
protected void |
resetDataCellActions()
Called after the actions from getDataCellActions have been rendered to clear out the ActionList for the dataCellActions. |
protected void |
resetEditColumnActions()
Called after the actions from getEditColumnActions have been rendered to clear out the ActionList for the editColumnActions. |
protected void |
resetEditRowActions()
Called after the actions from getEditRowActions have been rendered to clear out the ActionList for the editRowActions. |
void |
setAutoCreateColumnsFromModel(boolean autoCreate)
Sets this table's autoCreateColumnsFromModel flag. |
void |
setCellEditor(int startRow,
int endRow,
int repeatRowFactor,
int startColumn,
int endColumn,
int repeatColumnFactor,
TableCellEditor editor)
Sets the cell editor for the specific cells located in the specified area determined by startRow, endRow, repeatRowFactor, startColumn, endColumn and repeatColumnFactor. |
void |
setCellEditor(int row,
int column,
TableCellEditor editor)
Sets the cell editor for the specific cell located at the row and column passed in. |
void |
setCellEditor(com.sas.swing.visuals.tableview.TableFormatAreaInterface area,
TableCellEditor editor)
|
void |
setCellIdsGenerated(boolean cellIdsGenerated)
Sets whether the TableView's cells should have an id property generated. |
void |
setCellRenderer(int startRow,
int endRow,
int repeatRowFactor,
int startColumn,
int endColumn,
int repeatColumnFactor,
TableCellRenderer renderer)
Sets the cell renderer for the specific cells located in the specified area determined by startRow, endRow, repeatRowFactor, startColumn, endColumn and repeatColumnFactor. |
void |
setCellRenderer(int row,
int column,
TableCellRenderer renderer)
Sets the cell renderer for the specific cell located at the row and column passed in. |
void |
setCellRenderer(com.sas.swing.visuals.tableview.TableFormatAreaInterface area,
TableCellRenderer renderer)
|
void |
setColumnHeader(BaseColumnHeader newHeader)
Sets the columnHeader for the TableView. |
void |
setColumnHeaderAreaRenderer(com.sas.servlet.tbeans.tableview.ColumnHeaderAreaRenderer customRenderer)
|
void |
setColumnModel(TableColumnModel columnModel)
Sets the column model for the TableView. |
void |
setCurrentColumn(int column)
Set the column number of the current column being displayed in the TableView. |
void |
setCurrentRow(int row)
Set the row number of the current row being displayed in the TableView. |
void |
setEditColumn(TableColumn column)
Sets the instance of TableColumn to use as the column, independent of the data, which contains the edit actions. |
void |
setEditController(HttpEditController newEditController)
Sets the controller class used to assist in editing the table. |
void |
setLocale(java.util.Locale loc)
Set the locale on the TableView and all the classes used by the TableView. |
void |
setModel(javax.swing.table.TableModel tableModel)
Sets the data model for the TableView. |
void |
setNoRowsRenderer(TableCellContentsRenderer renderer)
Sets the cell content renderer to use for the TableView when there are no rows in the TableView or the model is not set. |
void |
setRowHeader(BaseRowHeader newHeader)
Sets the rowHeader for the TableView. |
void |
setRowModel(TableRowModel rowModel)
Sets the row model for the TableView. |
void |
setRowRenderer(int startRow,
int endRow,
int repeatRowFactor,
TableRowRenderer renderer)
Sets the row renderer for the specific row(s) passed in determind by startRow, endRow, and repeatRowFactor. |
void |
setRowRenderer(int row,
TableRowRenderer renderer)
Sets the row renderer for the specific row passed in. |
void |
setRowSelectionColumn(TableColumn column)
Sets an instance of TableColumn to use as the column, independent of the data, that can be used to select rows in the TableView. |
void |
setRowsToDelete(java.util.Map rows)
Sets the map containing the name/value pairs of the rows selected for deletion. |
void |
setUncommittedValues(java.util.Map values)
Sets the map containing the name/value pairs of the editable fields that have changed and need to be committed. |
void |
tableChanged(javax.swing.event.TableModelEvent e)
Invoked when this table's TableModel generates
a TableModelEvent . |
void |
update(int row)
Changes the given row from browse mode to edit mode. |
void |
write(java.io.PrintWriter out)
Writes the full version of the transformation which includes the following content: Opening container html element. |
void |
writeColumnHeader(java.io.PrintWriter out)
Writes the headerValue for each column in the column model. |
protected void |
writeContent(java.io.PrintWriter out)
Writes the transformation's main content which is everything except for the following: Opening container html element. |
void |
writeRow(int rowNumber,
java.io.OutputStream out)
Writes a single row of the TableView. |
void |
writeRow(int rowNumber,
java.io.PrintWriter out)
Writes a single row of the TableView. |
void |
writeRow(int rowNumber,
java.io.Writer out)
Writes a single row of the TableView. |
protected void |
writeRows(java.io.PrintWriter out)
Writes the rows of data for the tableview. |
Methods inherited from class com.sas.servlet.tbeans.BaseActionTransformation |
---|
dispose, getActionProvider, getActionSupportType, getUniqueId, isActionVisible, listActionTypes, listAreaTypes, setActionProvider, setActionSupportType, setActionVisible, setUniqueId |
Methods inherited from interface com.sas.actionprovider.URLTemplateViewInterface |
---|
getURLTemplate, setURLTemplate |
Methods inherited from interface com.sas.servlet.tbeans.TransformationInterface |
---|
getCustomAttributes, getDescription, getId, getLocale, getName, getRequest, getResponse, getTagEpilog, getTagProlog, isVisible, setCustomAttributes, setDescription, setId, setName, setRequest, setResponse, setTagEpilog, setTagProlog, setVisible, write, write, write |
Methods inherited from interface com.sas.actionprovider.HttpActionProviderViewInterface |
---|
getRequest, setRequest |
Field Detail |
---|
public static final int LASTROW
public static final int EDITROW
protected java.lang.String[] columnsToExportAsTextIfCustomFormatted
protected java.lang.String[] columnsToNotEncode
Constructor Detail |
---|
public BaseTableView()
Method Detail |
---|
public javax.swing.table.TableModel getModel()
setModel(javax.swing.table.TableModel)
public void setModel(javax.swing.table.TableModel tableModel)
tableModel
- the data model for the TableViewgetModel()
public TableColumnModel getColumnModel()
public void setColumnModel(TableColumnModel columnModel)
columnModel
- the column model for the TableViewpublic abstract TableColumnModel getDefaultColumnModel()
public void setAutoCreateColumnsFromModel(boolean autoCreate)
autoCreate
- true if TableView should automatically create columns
from the data modelgetAutoCreateColumnsFromModel()
,
createDefaultColumnsFromModel()
public boolean getAutoCreateColumnsFromModel()
setAutoCreateColumnsFromModel(boolean)
,
createDefaultColumnsFromModel()
public void createDefaultColumnsFromModel()
Clears any existing columns before creating the new columns based on information from the model.
getAutoCreateColumnsFromModel()
public TableRowModel getRowModel()
public void setRowModel(TableRowModel rowModel)
rowModel
- the row model for the TableViewpublic abstract TableRowModel getDefaultRowModel()
public int getCurrentRow()
getCurrentRow
in interface EditNavigationInterface
setCurrentRow(int)
public void setCurrentRow(int row)
row
- the row number of the current row being displayed in the TableViewgetCurrentRow()
public int getCurrentColumn()
setCurrentColumn(int)
public void setCurrentColumn(int column)
column
- the column number of the current column being displayed in the TableViewgetCurrentColumn()
public void setColumnHeader(BaseColumnHeader newHeader)
newHeader
- the new columnHeader for the TableViewpublic BaseColumnHeader getColumnHeader()
public abstract BaseColumnHeader getDefaultColumnHeader()
public void setRowHeader(BaseRowHeader newHeader)
newHeader
- the new rowHeader for the TableViewpublic BaseRowHeader getRowHeader()
public abstract BaseRowHeader getDefaultRowHeader()
public void setEditController(HttpEditController newEditController)
controller
- the new edit controllerHttpEditController
public HttpEditController getEditController()
HttpEditController
public abstract HttpEditController getDefaultEditController()
HttpEditController
public abstract TableRowRenderer getDefaultColumnHeaderRowRenderer()
public abstract TableRowRenderer getDefaultRowRenderer()
public void setRowRenderer(int row, TableRowRenderer renderer)
row
- the row to set the renderer on, -1 if setting the renderer on the entire table is desiredrenderer
- the renderer to use for the row, null to remove the renderer if previously setsetRowRenderer(int, int, int, TableRowRenderer)
,
getRowRenderer(int)
public void setRowRenderer(int startRow, int endRow, int repeatRowFactor, TableRowRenderer renderer)
The valid values for startRow are:
start >= 1The valid values for endRow are:
end >= start, or end == -1 for all rowsThe valid values for repeatRowFactor are:
repeat >= 1
If the renderer is null, it sets the renderer to be null, it will use the default row renderer set on the table. The last renderer applied always wins.
startRow
- the first row to set the renderer onendRow
- the last row to set the renderer on or -1 for all rows after startRowrepeatRowFactor
- specifies every nth row after the startRow to set the
renderer onrenderer
- the renderer to use for the row, null to remove the renderer if previously setsetRowRenderer(int, TableRowRenderer)
,
getRowRenderer(int)
public TableRowRenderer getRowRenderer(int row)
setRowRenderer
method and returns thats. If not, returns the
default row renderer for the TableView.
row
- the row to render
setRowRenderer(int, TableRowRenderer)
,
setRowRenderer(int, int, int, TableRowRenderer)
public abstract TableCellRenderer getDefaultRenderer()
public void setCellRenderer(int row, int column, TableCellRenderer renderer)
row
- the row to set the renderer on, -1 if setting the renderer
on the entire column is desiredcolumn
- the column to set the renderer on, -1 if setting the renderer
on the entire row is desiredrenderer
- the renderer to use for the row and column, null to remove
the renderer if previously setsetCellRenderer(int, int, int, int, int, int, TableCellRenderer)
,
getCellRenderer(int, int)
public void setCellRenderer(int startRow, int endRow, int repeatRowFactor, int startColumn, int endColumn, int repeatColumnFactor, TableCellRenderer renderer)
The valid values for startRow and startColumn are:
start >= 1The valid values for endRow and endColumn are:
end >= start, or end == -1 for all rows/columnsThe valid values for repeatRowFactor and repeatColumnFactor are:
repeat >= 1
If the renderer is null, it sets the renderer for the specified area of cells to be null, and the tableview will use the renderer set on the table column, or if that is also null, the tableview will use the default renderer set on the tableview.
If a renderer is set for an entire row, and then a different renderer is set for the same row, but a specific column, the second renderer will be used for that cell. The last renderer applied always wins. So if a bunch of renderers are set for rows, columns, and individual cells, and then a renderer is set for the entire tableview (i.e. startRow=1, endRow=-1, repeatRowFactor=1, startColumn=1, endColumn=-1, repeatColumnFactor=1), then the entire tableview will use the same renderer.
startRow
- the first row in the specified area to set the renderer onendRow
- the last row in the specified area to set the renderer on or
-1 for all rows after startRowrepeatRowFactor
- specifies every nth row after the startRow to set the
renderer onstartColumn
- the first column in the specified area to set the renderer onendColumn
- the last column in the specified area to set the renderer on or
-1 for all columns after startColumnrepeatColumnFactor
- specifies every nth column after the startColumn to set the
renderer onrenderer
- the renderer to use for specified area or null to remove the
renderer for the specified areasetCellRenderer(int, int, TableCellRenderer)
,
getCellRenderer(int, int)
public void setCellRenderer(com.sas.swing.visuals.tableview.TableFormatAreaInterface area, TableCellRenderer renderer)
public TableCellRenderer getCellRenderer(int row, int column)
setCellRenderer
methods and returns that. If not, it then checks
the TableColumn
for the specific column to see if it has a non-null
renderer, if so, returns that. If not, returns the default renderer for the TableView.
Note: Throughout the tableview package, the internal implementations always use this method to provide renderers so that this default behavior can be safely overridden by a subclass.
row
- the row of the cell to rendercolumn
- the column of the cell to render
setCellRenderer(int, int, TableCellRenderer)
,
setCellRenderer(int, int, int, int, int, int, TableCellRenderer)
public void setColumnHeaderAreaRenderer(com.sas.servlet.tbeans.tableview.ColumnHeaderAreaRenderer customRenderer)
public com.sas.servlet.tbeans.tableview.ColumnHeaderAreaRenderer getColumnHeaderAreaRenderer()
public abstract TableCellEditor getDefaultEditor()
public void setCellEditor(int row, int column, TableCellEditor editor)
row
- the row to set the editor on, -1 if setting the editor
on the entire column is desiredcolumn
- the column to set the editor on, -1 if setting the editor
on the entire row is desirededitor
- the editor to use for the row and column, null to remove
the editor if previously setsetCellEditor(int, int, int, int, int, int, TableCellEditor)
,
getCellEditor(int, int)
public void setCellEditor(int startRow, int endRow, int repeatRowFactor, int startColumn, int endColumn, int repeatColumnFactor, TableCellEditor editor)
The valid values for startRow and startColumn are:
start >= 1The valid values for endRow and endColumn are:
end >= start, or end == -1 for all rows/columnsThe valid values for repeatRowFactor and repeatColumnFactor are:
repeat >= 1
If the editor is null, it sets the editor for the specified area of cells to be null, and the tableview will use the editor set on the table column, or if that is also null, the tableview will use the default editor set on the tableview.
If a editor is set for an entire row, and then a different editor is set for the same row, but a specific column, the second editor will be used for that cell. The last editor applied always wins. So if a bunch of editors are set for rows, columns, and individual cells, and then a editor is set for the entire tableview (i.e. startRow=1, endRow=-1, repeatRowFactor=1, startColumn=1, endColumn=-1, repeatColumnFactor=1), then the entire tableview will use the same editor.
startRow
- the first row in the specified area to set the editor onendRow
- the last row in the specified area to set the editor on or
-1 for all rows after startRowrepeatRowFactor
- specifies every nth row after the startRow to set the
editor onstartColumn
- the first column in the specified area to set the editor onendColumn
- the last column in the specified area to set the editor on or
-1 for all columns after startColumnrepeatColumnFactor
- specifies every nth column after the startColumn to set the
editor oneditor
- the editor to use for specified area or null to remove the
editor for the specified areasetCellEditor(int, int, TableCellEditor)
,
getCellEditor(int, int)
public void setCellEditor(com.sas.swing.visuals.tableview.TableFormatAreaInterface area, TableCellEditor editor)
public TableCellEditor getCellEditor(int row, int column)
setCellEditor
methods and returns that. If not, it then checks
the TableColumn
for the specific column to see if it has a non-null
editor, if so, returns that. If not, returns the default editor for the TableView.
Note: Throughout the tableview package, the internal implementations always use this method to provide editors so that this default behavior can be safely overridden by a subclass.
row
- the row of the cell to editcolumn
- the column of the cell to edit
setCellEditor(int, int, TableCellEditor)
,
setCellEditor(int, int, int, int, int, int, TableCellEditor)
public TableCellContentsRenderer getNoRowsRenderer()
public void setNoRowsRenderer(TableCellContentsRenderer renderer)
renderer
- an instance of the TableCellContentsRendererpublic abstract TableCellContentsRenderer getDefaultNoRowsRenderer()
public void cleanUpResources()
request
and response
. This method
calls the setRequest and setResponse methods with a null value.
cleanUpResources
in class BaseTransformation
public void writeColumnHeader(java.io.PrintWriter out) throws java.io.IOException
writeColumnHeader
in class AbstractBaseTableView
out
- the output stream
java.io.IOException
- Thrown if some type of I/O error occursprotected ActionList getColumnHeaderActions(TableColumn column, java.lang.String header)
column
- The column to get the actions for. Should be an instance of TableColumn.header
- The name to use as the column's header.
resetColumnHeaderActions()
protected void resetColumnHeaderActions()
getColumnHeaderActions(com.sas.servlet.tbeans.tableview.TableColumn, java.lang.String)
protected void writeRows(java.io.PrintWriter out) throws java.io.IOException
writeRows
in class AbstractBaseTableView
out
- The output stream
java.io.IOException
- Thrown if some type of I/O error occurspublic void writeRow(int rowNumber, java.io.Writer out) throws java.io.IOException
rowNumber
- the 1-based row number to writeout
- the output stream
java.io.IOException
- Thrown if some type of I/O error occurspublic void writeRow(int rowNumber, java.io.OutputStream out) throws java.io.IOException
rowNumber
- the 1-based row number to writeout
- the output stream
java.io.IOException
- Thrown if some type of I/O error occurspublic void writeRow(int rowNumber, java.io.PrintWriter out) throws java.io.IOException
rowNumber
- the 1-based row number to writeout
- the output stream
java.io.IOException
- Thrown if some type of I/O error occursprotected ActionList getEditRowActions()
resetEditRowActions()
protected void resetEditRowActions()
getEditRowActions()
protected ActionList getEditColumnActions(int rowNumber)
rowNumber
- The row used to return actions.
resetEditColumnActions()
protected void resetEditColumnActions()
getEditColumnActions(int)
protected ActionList getDataCellActions(int rowNumber, int colModelIndex)
rowNumber
- The data model's index for the row.colModelIndex
- The data model's index for the column.
resetDataCellActions()
protected void resetDataCellActions()
getDataCellActions(int, int)
protected int getMultiColumnRuleCount()
public void initialize()
initialize
in class AbstractBaseTableView
public void initializeRowNumbers()
public void initializeColumnNumbers()
public int getRowCount()
getRowCount
in interface RowNavigationInterface
getRowCount
in class AbstractBaseTableView
public int getColumnCount()
getColumnCount
in interface ColumnNavigationInterface
getColumnCount
in class AbstractBaseTableView
public boolean isGotoRowSupported()
isGotoRowSupported
in interface RowNavigationInterface
isGotoRowSupported
in class AbstractBaseTableView
AbstractBaseTableView.gotoRow(int)
public boolean isGotoColumnSupported()
isGotoColumnSupported
in interface ColumnNavigationInterface
isGotoColumnSupported
in class AbstractBaseTableView
AbstractBaseTableView.gotoColumn(int)
public boolean isAccurateRowCountAvailable()
isAccurateRowCountAvailable
in interface AccurateRowCountInterface
isAccurateRowCountAvailable
in class AbstractBaseTableView
java.lang.IllegalStateException
- Thrown if the TableView's model
has not yet been set.public void tableChanged(javax.swing.event.TableModelEvent e)
TableModel
generates
a TableModelEvent
.
The TableModelEvent
should be constructed in the
coordinate system of the model. The appropriate mapping to the
view coordinate system is performed by this TableView
when it receives the event.
Application code will not use these methods explicitly, they
are used internally by TableView
.
tableChanged
in interface javax.swing.event.TableModelListener
event
- the TableModelEventpublic boolean isUpdateSupported()
isUpdateSupported
in interface EditNavigationInterface
EditNavigationInterface.update(int)
public boolean isInsertSupported()
isInsertSupported
in interface EditNavigationInterface
EditNavigationInterface.insert(int)
public boolean isDeleteSupported()
isDeleteSupported
in interface EditNavigationInterface
EditNavigationInterface.delete(int)
public boolean isCommitSupported()
isCommitSupported
in interface EditNavigationInterface
EditNavigationInterface.commit()
public boolean isCancelSupported()
isCancelSupported
in interface EditNavigationInterface
EditNavigationInterface.cancel()
public boolean isAutoCommit()
isAutoCommit
in interface EditNavigationInterface
public boolean isPromptOnDelete()
isPromptOnDelete
in interface EditNavigationInterface
public void delete(int row)
delete
in interface EditNavigationInterface
row
- the row to delete
java.lang.UnsupportedOperationException
- Thrown if isDeleteSupported()
returns falseisDeleteSupported()
public void insert(int row)
insert
in interface EditNavigationInterface
row
- the row to insert before
java.lang.UnsupportedOperationException
- Thrown if isInsertSupported()
returns falseisInsertSupported()
public void cancel()
cancel
in interface EditNavigationInterface
java.lang.UnsupportedOperationException
- Thrown if isCancelSupported()
returns falseisCancelSupported()
public void commit()
commit
in interface EditNavigationInterface
java.lang.UnsupportedOperationException
- Thrown if isCommitSupported()
returns falseisCommitSupported()
public void update(int row)
update
in interface EditNavigationInterface
row
- the row to update
java.lang.UnsupportedOperationException
- Thrown if isUpdateSupported()
returns falseisUpdateSupported()
public void setUncommittedValues(java.util.Map values)
setUncommittedValues
in interface EditNavigationInterface
values
- the map containing the name/value pairs of the editable
fields that need to be committedgetUncommittedValues()
public java.util.Map getUncommittedValues()
setUncommittedValues(java.util.Map)
public void setRowsToDelete(java.util.Map rows)
setRowsToDelete
in interface EditNavigationInterface
values
- the map containing the name/value pairs of the selected
rows to be deletedgetRowsToDelete()
public java.util.Map getRowsToDelete()
setRowsToDelete(java.util.Map)
public TableColumn getColumn(java.lang.Object identifier)
identifier
- the identifier object
java.lang.IllegalArgumentException
- if identifier is null or no
TableColumn has this identifierTableColumnModel.getColumn(int)
public void addColumn(TableColumn column)
column
- the TableColumn to be added
java.lang.IllegalStateException
- Thrown if the TableView's model
has not yet been set.TableColumnModel.addColumn(com.sas.servlet.tbeans.tableview.TableColumn)
public void removeColumn(TableColumn column)
column
- the TableColumn to be removedTableColumnModel.removeColumn(com.sas.servlet.tbeans.tableview.TableColumn)
public void moveColumn(int column, int targetColumn)
moveColumn
in interface com.sas.table.MoveColumnInterface
column
- the index of column to be movedtargetColumn
- the new index of the columnTableColumnModel.moveColumn(int, int)
public void columnAdded(TableColumnModelEvent event)
columnAdded
in interface TableColumnModelListener
event
- the event receivedTableColumnModelListener
public void columnRemoved(TableColumnModelEvent event)
columnRemoved
in interface TableColumnModelListener
event
- the event receivedTableColumnModelListener
public void columnMoved(TableColumnModelEvent event)
columnMoved
in interface TableColumnModelListener
event
- the event receivedTableColumnModelListener
public TableColumn getRowSelectionColumn()
setRowSelectionColumn(com.sas.servlet.tbeans.tableview.TableColumn)
,
setRowSelectionMode(int)
,
getRowSelectionMode()
public void setRowSelectionColumn(TableColumn column)
column
- the TableColumn used to represent a column that will
allow row selectiongetRowSelectionColumn()
,
setRowSelectionMode(int)
,
getRowSelectionMode()
public abstract TableColumn getDefaultRowSelectionColumn()
setRowSelectionMode(int)
,
getRowSelectionMode()
public TableColumn getEditColumn()
public void setEditColumn(TableColumn column)
public abstract TableColumn getDefaultEditColumn()
public void setLocale(java.util.Locale loc)
setLocale
in interface TransformationInterface
setLocale
in class BaseTransformation
loc
- an instance of java.util.Localepublic void lastRow()
lastRow
in interface RowNavigationInterface
lastRow
in class AbstractBaseTableView
java.lang.UnsupportedOperationException
- Thrown if
isLastRowSupported() returns falseAbstractBaseTableView.isLastRowSupported()
public void gotoRow(int row)
gotoRow
in interface RowNavigationInterface
gotoRow
in class AbstractBaseTableView
row
- the row index
java.lang.UnsupportedOperationException
- Thrown if
isGotoRowSupported() returns falseisGotoRowSupported()
public boolean isColumnMoveAllowed(int columnIndex, int newIndex)
isColumnMoveAllowed
in interface com.sas.table.MoveColumnInterface
columnIndex
- The index of the column to be moved.newIndex
- The index of the column's new location.
public int getColumnScrollSize()
AbstractBaseTableView
getColumnScrollSize
in class AbstractBaseTableView
public boolean isCellIdsGenerated()
public void setCellIdsGenerated(boolean cellIdsGenerated)
cellIdsGenerated
- The cellIdsGenerated to set.public void write(java.io.PrintWriter out) throws java.io.IOException
BaseActionTransformation2
write
in interface TransformationInterface
write
in interface com.sas.util.WriteToPrintWriterInterface
write
in class com.sas.servlet.tbeans.BaseActionTransformation2
out
- The output stream to which the full content
is written.
java.io.IOException
- Thrown if some type of I/O error occurs#preWrite(PrintWriter)
,
BaseActionTransformation2.writeContent(PrintWriter)
,
#postWrite(PrintWriter)
protected void writeContent(java.io.PrintWriter out) throws java.io.IOException
BaseActionTransformation2
writeContent
in class AbstractBaseTableView
java.io.IOException
BaseActionTransformation2.write(PrintWriter)
public boolean isExportNumericCustomFormattedValuesAsText(int colModelIndex)
colModelIndex
- The 1-based index of the column in the TableModelprotected java.lang.String getColumnUniqueModelId(int colModelIndex)
protected java.lang.String[] getColumnsToExportAsTextIfCustomFormatted(com.sas.iquery.metadata.business.DataItem[] dataItems)
public boolean isCurrentValueToEncode()
isCurrentValueToEncode
in interface ExportAsHyperlinkInterface
ExportAsHyperlinkInterface
|
Components |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |