org.rosuda.deducer.data
Class RDataFrameModel

java.lang.Object
  extended by javax.swing.table.AbstractTableModel
      extended by javax.swing.table.DefaultTableModel
          extended by org.rosuda.deducer.data.ExDefaultTableModel
              extended by org.rosuda.deducer.data.RDataFrameModel
All Implemented Interfaces:
java.io.Serializable, javax.swing.table.TableModel

public class RDataFrameModel
extends ExDefaultTableModel

Data Frame model

Author:
ifellows
See Also:
Serialized Form

Nested Class Summary
 class RDataFrameModel.RCellRenderer
          Implements nice printing of NAs, as well as left alignment for strings and right alignment for numbers.
 
Field Summary
static java.lang.String NA_STRING
           
static int numExtensionColumns
           
static int numExtensionRows
           
 
Fields inherited from class javax.swing.table.DefaultTableModel
columnIdentifiers, dataVector
 
Fields inherited from class javax.swing.table.AbstractTableModel
listenerList
 
Constructor Summary
RDataFrameModel()
           
RDataFrameModel(java.lang.String name)
           
 
Method Summary
 void declarePending(int row, int col)
           
 void eraseRange(int row1, int row2, int col1, int col2)
           
protected  void finalize()
           
 java.lang.Object getActualValueAt(int row, int col)
           
 int getColumnCount()
           
 java.lang.String getColumnName(int col)
           
 java.lang.String getDataName()
           
 java.lang.String getPageValue(int row, int col)
           
 java.lang.Object[][] getRange(int row1, int row2, int col1, int col2)
           
 int getRealColumnCount()
           
 int getRealRowCount()
           
 int getRowCount()
           
 RowNamesListModel getRowNamesModel()
           
 java.lang.Object getValueAt(int row, int col)
           
 void insertNewColumn(int col)
           
 void insertNewRow(int row)
           
 boolean isCellEditable(int rowIndex, int columnIndex)
           
 boolean isPending(int row, int col)
           
 void lazyLoad(int row, int col)
           
 void loadPage(int row, int col)
           
 boolean pending(int row, int col)
           
 void populateMetaData()
           
 boolean refresh()
          Notifies components about changes in the model
 void removeCachedData()
          Deletes the cached data frame from the gui environment
 void removeColumn(int colNumber)
           
 void removePending(int row, int col)
           
 void removeRow(int row)
           
 void setDataName(java.lang.String name)
           
 boolean setPageValue(java.lang.String value, int row, int col)
           
 void setRange(java.lang.Object[][] values, int row, int col)
           
 void setRowNamesModel(org.rosuda.deducer.data.RDataFrameModel.RowNamesModel model)
           
 void setValueAt(java.lang.Object value, int row, int col)
           
 
Methods inherited from class javax.swing.table.DefaultTableModel
addColumn, addColumn, addColumn, addRow, addRow, convertToVector, convertToVector, getDataVector, insertRow, insertRow, moveRow, newDataAvailable, newRowsAdded, rowsRemoved, setColumnCount, setColumnIdentifiers, setColumnIdentifiers, setDataVector, setDataVector, setNumRows, setRowCount
 
Methods inherited from class javax.swing.table.AbstractTableModel
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getColumnClass, getListeners, getTableModelListeners, removeTableModelListener
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NA_STRING

public static java.lang.String NA_STRING

numExtensionRows

public static final int numExtensionRows
See Also:
Constant Field Values

numExtensionColumns

public static final int numExtensionColumns
See Also:
Constant Field Values
Constructor Detail

RDataFrameModel

public RDataFrameModel()

RDataFrameModel

public RDataFrameModel(java.lang.String name)
Method Detail

getDataName

public java.lang.String getDataName()

setDataName

public void setDataName(java.lang.String name)

populateMetaData

public void populateMetaData()

getColumnCount

public int getColumnCount()
Specified by:
getColumnCount in interface javax.swing.table.TableModel
Overrides:
getColumnCount in class javax.swing.table.DefaultTableModel

getRealColumnCount

public int getRealColumnCount()

getRealRowCount

public int getRealRowCount()

getRowCount

public int getRowCount()
Specified by:
getRowCount in interface javax.swing.table.TableModel
Overrides:
getRowCount in class javax.swing.table.DefaultTableModel

removeColumn

public void removeColumn(int colNumber)
Overrides:
removeColumn in class ExDefaultTableModel

removeRow

public void removeRow(int row)
Overrides:
removeRow in class ExDefaultTableModel

insertNewColumn

public void insertNewColumn(int col)
Overrides:
insertNewColumn in class ExDefaultTableModel

insertNewRow

public void insertNewRow(int row)
Overrides:
insertNewRow in class ExDefaultTableModel

getPageValue

public java.lang.String getPageValue(int row,
                                     int col)

setPageValue

public boolean setPageValue(java.lang.String value,
                            int row,
                            int col)

lazyLoad

public void lazyLoad(int row,
                     int col)

pending

public boolean pending(int row,
                       int col)

isPending

public boolean isPending(int row,
                         int col)

declarePending

public void declarePending(int row,
                           int col)

removePending

public void removePending(int row,
                          int col)

loadPage

public void loadPage(int row,
                     int col)

getValueAt

public java.lang.Object getValueAt(int row,
                                   int col)
Specified by:
getValueAt in interface javax.swing.table.TableModel
Overrides:
getValueAt in class javax.swing.table.DefaultTableModel

getActualValueAt

public java.lang.Object getActualValueAt(int row,
                                         int col)
Overrides:
getActualValueAt in class ExDefaultTableModel

setValueAt

public void setValueAt(java.lang.Object value,
                       int row,
                       int col)
Specified by:
setValueAt in interface javax.swing.table.TableModel
Overrides:
setValueAt in class javax.swing.table.DefaultTableModel

getRange

public java.lang.Object[][] getRange(int row1,
                                     int row2,
                                     int col1,
                                     int col2)
Overrides:
getRange in class ExDefaultTableModel

setRange

public void setRange(java.lang.Object[][] values,
                     int row,
                     int col)
Overrides:
setRange in class ExDefaultTableModel

eraseRange

public void eraseRange(int row1,
                       int row2,
                       int col1,
                       int col2)
Overrides:
eraseRange in class ExDefaultTableModel

refresh

public boolean refresh()
Notifies components about changes in the model


getColumnName

public java.lang.String getColumnName(int col)
Specified by:
getColumnName in interface javax.swing.table.TableModel
Overrides:
getColumnName in class javax.swing.table.DefaultTableModel

isCellEditable

public boolean isCellEditable(int rowIndex,
                              int columnIndex)
Specified by:
isCellEditable in interface javax.swing.table.TableModel
Overrides:
isCellEditable in class javax.swing.table.DefaultTableModel

removeCachedData

public void removeCachedData()
Deletes the cached data frame from the gui environment


finalize

protected void finalize()
                 throws java.lang.Throwable
Overrides:
finalize in class java.lang.Object
Throws:
java.lang.Throwable

getRowNamesModel

public RowNamesListModel getRowNamesModel()

setRowNamesModel

public void setRowNamesModel(org.rosuda.deducer.data.RDataFrameModel.RowNamesModel model)