|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.swing.table.AbstractTableModel
com.jaxfront.core.ui.FlipOrientationTableModel
public class FlipOrientationTableModel
The FlipOrientationTableModel is the model counter part to the RowHeadedTable. This model can be fliped so all columns will becom rows and vis versa.
Constructor Summary | |
---|---|
FlipOrientationTableModel(AbstractListType listType)
|
|
FlipOrientationTableModel(ListType listType)
Constructor from a complex group list Extracts table info from the complex group list' XU definition OR if that is not defined, creates the table info by looking for SimpleTypes and SimpleTypeLists in the ComplexGroupList |
Method Summary | |
---|---|
void |
domChanged(DOMChangeEvent event)
Respond method for a DOM state changed (DOMChangeEvent). |
java.lang.Object |
getCachedValueAt(int row,
int col)
|
java.lang.Class |
getColumnClass(int columnIndex)
|
int |
getColumnCount()
Get the number of columns in the table Value depends on whether the table is flipped (This is used by the JTable displaying this model) |
java.lang.String |
getColumnName(int col)
Get the column name at index col. |
java.lang.String |
getExcelTableData()
Returns the table's contents in a format that Excel can handle (tab, newline separated) |
int |
getIndexFor(Type type)
Returns the index within the holding listType of the passing type. |
ListType |
getListType()
Returns the holding list type. |
int |
getRowCount()
Count the number of rows in the table.Value depends on whether the table is flipped |
java.util.List |
getRowFormulas(int col)
|
java.util.Vector |
getRowHeaders()
|
java.lang.String |
getRowName(int index)
|
java.lang.String[] |
getRowValues(int row)
|
SimpleType |
getSimpleTypeAt(int row,
int col)
Returns a simple type for a row and a column. |
RowHeaderLabellingStrategy |
getStrategy()
Accessor to the labelling strategy needed by the view. |
TableInfo |
getTableInfo()
Accessor to the table info. |
Type |
getTypeAt(int row,
int col)
Returns a simple type for a row and a column. |
java.lang.Object |
getValueAt(int row,
int col)
Get the Object at position row, column Returns the approriate object from the internal object table, location depends on row, column but also on whether the table is flipped or not. col = 0 will always return the rowHeaders for the table. |
boolean |
isCellEditable(int row,
int column)
|
boolean |
isCellEditableEnabled()
Returns true if cells are editable. |
boolean |
isFlipped()
Accessor to the flipped flag. |
void |
release()
Releases alocated resources. |
void |
setFlipped(boolean flipped)
Sets if the table is flipped. |
void |
setValueAt(java.lang.Object aValue,
int rowIndex,
int columnIndex)
|
boolean |
showRowHeaders()
Accessor to the showRowHeaders field. |
void |
swapFormula(int from,
int to)
Swaps the formula from one type to another. |
Methods inherited from class javax.swing.table.AbstractTableModel |
---|
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getListeners, getTableModelListeners, removeTableModelListener |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FlipOrientationTableModel(ListType listType)
listType
- public FlipOrientationTableModel(AbstractListType listType)
Method Detail |
---|
public void domChanged(DOMChangeEvent event)
DOMChangeListener
domChanged
in interface DOMChangeListener
event
- occured DOMChangeEventDOMChangeListener.domChanged(DOMChangeEvent)
public java.lang.Class getColumnClass(int columnIndex)
getColumnClass
in interface javax.swing.table.TableModel
getColumnClass
in class javax.swing.table.AbstractTableModel
TableModel.getColumnClass(int)
public int getColumnCount()
getColumnCount
in interface javax.swing.table.TableModel
TableModel.getColumnCount()
public java.lang.String getColumnName(int col)
getColumnName
in interface javax.swing.table.TableModel
getColumnName
in class javax.swing.table.AbstractTableModel
col
- the column to selectTableModel.getColumnName(int)
public java.lang.String getRowName(int index)
public java.lang.String getExcelTableData()
public int getIndexFor(Type type)
type
- to lookup index forpublic ListType getListType()
public int getRowCount()
getRowCount
in interface javax.swing.table.TableModel
TableModel.getRowCount()
public SimpleType getSimpleTypeAt(int row, int col)
row
- row to lookupcol
- column to lookuppublic Type getTypeAt(int row, int col)
row
- row to lookupcol
- column to lookuppublic RowHeaderLabellingStrategy getStrategy()
public TableInfo getTableInfo()
public java.lang.Object getValueAt(int row, int col)
getValueAt
in interface javax.swing.table.TableModel
row
- The row to selectcol
- The column to select
public java.util.List getRowFormulas(int col)
public java.lang.Object getCachedValueAt(int row, int col)
public boolean isCellEditable(int row, int column)
isCellEditable
in interface javax.swing.table.TableModel
isCellEditable
in class javax.swing.table.AbstractTableModel
TableModel.isCellEditable(int, int)
public boolean isCellEditableEnabled()
public boolean isFlipped()
public void setFlipped(boolean flipped)
flipped
- indicates if table is flippedpublic void setValueAt(java.lang.Object aValue, int rowIndex, int columnIndex)
setValueAt
in interface javax.swing.table.TableModel
setValueAt
in class javax.swing.table.AbstractTableModel
TableModel.setValueAt(Object, int, int)
public boolean showRowHeaders()
public void swapFormula(int from, int to)
fromType
- base typetoType
- target typepublic void release()
public java.util.Vector getRowHeaders()
public java.lang.String[] getRowValues(int row)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |