Simple Machine

util
Class AbstractDataModel

java.lang.Object
  extended by java.util.Observable
      extended by util.AbstractDataModel
All Implemented Interfaces:
DataModel
Direct Known Subclasses:
AbstractMainMemory, CompoundModel, PickModel, Register, RegisterSet

public abstract class AbstractDataModel
extends Observable
implements DataModel


Constructor Summary
AbstractDataModel()
           
 
Method Summary
 void addUndoableEditListener(UndoableEditListener l)
           
 boolean canDeleteRow(int rowIndex)
           
 boolean canInsertRow(int rowIndex)
           
 boolean deleteRow(int rowIndex)
           
 Class getColumnClass(int col)
           
 int getColumnCount()
           
 String getColumnName(int col)
           
 int getRowCount()
           
 Object getValueAt(int row, int col)
           
 boolean insertRow(int rowIndex)
           
 boolean isCellEditable(int row, int col)
           
 void setValueAt(Object[] aValue, int rowIndex, int columnIndex)
           
 void setValueAt(Object value, int row, int col)
           
 void setValueAtByUser(Object[] aValue, int rowIndex, int columnIndex)
           
 void setValueAtByUser(Object value, int row, int col)
           
protected  void tellObservers(DataModelEvent e)
           
protected  void tellObservers(List<DataModelEvent> el)
           
 
Methods inherited from class java.util.Observable
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface util.DataModel
addObserver
 

Constructor Detail

AbstractDataModel

public AbstractDataModel()
Method Detail

tellObservers

protected void tellObservers(DataModelEvent e)

tellObservers

protected void tellObservers(List<DataModelEvent> el)

setValueAt

public void setValueAt(Object[] aValue,
                       int rowIndex,
                       int columnIndex)
Specified by:
setValueAt in interface DataModel

insertRow

public boolean insertRow(int rowIndex)
Specified by:
insertRow in interface DataModel

deleteRow

public boolean deleteRow(int rowIndex)
Specified by:
deleteRow in interface DataModel

canInsertRow

public boolean canInsertRow(int rowIndex)
Specified by:
canInsertRow in interface DataModel

canDeleteRow

public boolean canDeleteRow(int rowIndex)
Specified by:
canDeleteRow in interface DataModel

addUndoableEditListener

public void addUndoableEditListener(UndoableEditListener l)
Specified by:
addUndoableEditListener in interface DataModel

getColumnClass

public Class getColumnClass(int col)
Specified by:
getColumnClass in interface DataModel

getColumnCount

public int getColumnCount()
Specified by:
getColumnCount in interface DataModel

getColumnName

public String getColumnName(int col)
Specified by:
getColumnName in interface DataModel

getRowCount

public int getRowCount()
Specified by:
getRowCount in interface DataModel

getValueAt

public Object getValueAt(int row,
                         int col)
Specified by:
getValueAt in interface DataModel

isCellEditable

public boolean isCellEditable(int row,
                              int col)
Specified by:
isCellEditable in interface DataModel

setValueAt

public void setValueAt(Object value,
                       int row,
                       int col)
Specified by:
setValueAt in interface DataModel

setValueAtByUser

public void setValueAtByUser(Object value,
                             int row,
                             int col)
Specified by:
setValueAtByUser in interface DataModel

setValueAtByUser

public void setValueAtByUser(Object[] aValue,
                             int rowIndex,
                             int columnIndex)
Specified by:
setValueAtByUser in interface DataModel

Simple Machine

Copyright © 2010, 2011 Mike Feeley. All Rights Reserved.