private void save(Trigger t) {
if (table.getCellEditor() != null) {
table.getCellEditor().stopCellEditing();
}
Payload payload = new Payload();
for (int r = 0; r < model.getRowCount(); r++) {
boolean saveCurrent = true;
for (int k = 0; k < 4; k++) {
String test = model.getValueAt(r, 0).toString();
if ((test == null) || test.equals("")) {
saveCurrent = false;
break;
}
}
if (saveCurrent) {
payload.addStatement(model.getValueAt(r, 0).toString(),
model.getValueAt(r, 1).toString(),
model.getValueAt(r, 2).toString(),
model.getValueAt(r, 3).toString());
}
}