nA exclusão de linhas é feita diretamente pelo
modelo nos dados e o método fireTableRowsDeleted(row-i,
row-f) avisa a JTable
nRemove linha
npublic void removeRow( int row ) {
getLinhas(). remove(0);
fireTableRowsDeleted(row,
row);
return;
n}
npublic boolean removeRow(String val, int col) {
n
Iterator i = getLinhas().iterator();
int row = 0;
while( i.hasNext() ) {
String[] rowCorrente = (String[])i.next(); row++;
if( rowCorrente[col].equals(val) ){
// procura valor na posicao
(row,col)
n
getLinhas().remove(row);
fireTableRowsDeleted(row, row);
return true;
}
}
return false;
n }
n