edu.stanford.smi.protegex.owl.ui.properties.range
Class UnionRangeClassesTableModel
java.lang.Object
javax.swing.table.AbstractTableModel
edu.stanford.smi.protegex.owl.ui.properties.range.UnionRangeClassesTableModel
- All Implemented Interfaces:
- OWLTableModel, Serializable, SymbolTableModel, TableModel
- class UnionRangeClassesTableModel
- extends AbstractTableModel
- implements OWLTableModel
An AbstractTableModel that represents each of the classes in the union range
of a property with one row.
- Author:
- Holger Knublauch
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 |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
propertyWidget
private PropertyWidget propertyWidget
rows
private List rows
- The List of RDFSClass instances in the table, sorted by rows
UnionRangeClassesTableModel
UnionRangeClassesTableModel(PropertyWidget propertyWidget)
addRow
public boolean addRow(RDFSClass aClass,
int rowIndex)
- Specified by:
addRow
in interface OWLTableModel
addEmptyRow
public int addEmptyRow(int rowIndex)
- Specified by:
addEmptyRow
in interface OWLTableModel
clearRows
void clearRows()
- Removes all rows from the table.
deleteRow
public void deleteRow(int index)
- Specified by:
deleteRow
in interface OWLTableModel
displaySemanticError
public void displaySemanticError(String message)
- Description copied from interface:
OWLTableModel
- Displays an illegal assignment error dialog, e.g. through a JOptionPane.
This can be used if someone tries to assign an illegal superclass to the model.
- Specified by:
displaySemanticError
in interface OWLTableModel
- Parameters:
message
- the message text
dispose
public void dispose()
- Specified by:
dispose
in interface OWLTableModel
getColumnCount
public int getColumnCount()
- Specified by:
getColumnCount
in interface TableModel
getColumnName
public String getColumnName(int column)
- Specified by:
getColumnName
in interface TableModel
getColumnClass
public Class getColumnClass(int columnIndex)
- Specified by:
getColumnClass
in interface TableModel
getClass
public RDFSClass getClass(int rowIndex)
- Specified by:
getClass
in interface OWLTableModel
getClassRow
public int getClassRow(RDFSClass cls)
- Specified by:
getClassRow
in interface OWLTableModel
getEditedCls
public OWLNamedClass getEditedCls()
- Specified by:
getEditedCls
in interface OWLTableModel
getEditedProperty
RDFProperty getEditedProperty()
getIcon
public Icon getIcon(RDFResource resource)
- Specified by:
getIcon
in interface SymbolTableModel
getPredicate
public RDFProperty getPredicate(int row)
- Specified by:
getPredicate
in interface SymbolTableModel
getRDFResource
public RDFResource getRDFResource(int row)
- Specified by:
getRDFResource
in interface SymbolTableModel
getRowCount
public int getRowCount()
- Specified by:
getRowCount
in interface TableModel
getSubject
public RDFResource getSubject()
- Specified by:
getSubject
in interface SymbolTableModel
getSymbolColumnIndex
public int getSymbolColumnIndex()
- Specified by:
getSymbolColumnIndex
in interface SymbolTableModel
getValueAt
public Object getValueAt(int rowIndex,
int columnIndex)
- Specified by:
getValueAt
in interface TableModel
getValues
Collection getValues()
insertRow
private void insertRow(RDFSClass cls)
isAddEnabledAt
public boolean isAddEnabledAt(int rowIndex)
- Specified by:
isAddEnabledAt
in interface OWLTableModel
isCellEditable
public boolean isCellEditable(int rowIndex,
int columnIndex)
- Specified by:
isCellEditable
in interface TableModel
isDeleteEnabledFor
public boolean isDeleteEnabledFor(RDFSClass cls)
- Specified by:
isDeleteEnabledFor
in interface OWLTableModel
isEditable
public boolean isEditable()
- Specified by:
isEditable
in interface OWLTableModel
isInherited
boolean isInherited(RDFSClass cls)
refill
void refill()
removeEmptyRow
public void removeEmptyRow()
- Specified by:
removeEmptyRow
in interface OWLTableModel
removeSuperclasses
private void removeSuperclasses(Collection clses,
RDFSClass aClass)
setCls
public void setCls(OWLNamedClass cls)
- Specified by:
setCls
in interface OWLTableModel
setValueAt
public void setValueAt(Object value,
int rowIndex,
int columnIndex)
- Specified by:
setValueAt
in interface TableModel