throw new TableSelectionException("Cutting is allowed only on 'Aspects'.");
// find out what aspects to cut
HashSet myRememberList = new HashSet();
for (int i=0; i < selectedCells.length; i++) {
AspectSurrogate aspect = (AspectSurrogate)((Vector)data.get(selectedCells[i])).get(JWorksheetProseClientPane.ASPECT_COL_INDEX);
if (aspect == null)
throw new TableSelectionException("Empty cells in selection!");
myRememberList.add(aspect);
}
// cut the aspects
Iterator toCut = myRememberList.iterator();
WithdrawAspectsException maE = new WithdrawAspectsException();
while (toCut.hasNext()) {
try {
if (parentModel.getActiveTransactionID() == null)
exMngr.withdraw((AspectSurrogate)toCut.next());
else
exMngr.withdraw((AspectSurrogate)toCut.next(),parentModel.getActiveTransactionID());
}
catch (Exception e) {
maE.add(e);
}
}
// update the table
for (int i=0; i < table.size(); i++) {
AspectSurrogate aspect = (AspectSurrogate)((Vector)data.get(i)).get(JWorksheetProseClientPane.ASPECT_COL_INDEX);
if (myRememberList.contains(aspect)) {
data.remove(i);
table.remove(i);
i--;
}