use of com.cubrid.cubridmanager.core.cubrid.database.model.lock.BlockedHolders in project cubrid-manager by CUBRID.
the class LockInfoDetailDialog method initial.
/**
*
* Initial data
*
*/
private void initial() {
if (dbLotEntry == null) {
return;
}
if (dbLotEntry.getLockHoldersList() != null) {
for (LockHolders bean : dbLotEntry.getLockHoldersList()) {
Map<String, String> map = new HashMap<String, String>();
map.put("0", String.valueOf(bean.getTran_index()));
map.put("1", bean.getGranted_mode());
map.put("2", String.valueOf(bean.getCount()));
map.put("3", String.valueOf(bean.getNsubgranules()));
lockHolderListData.add(map);
}
lockHolderTableViewer.refresh();
for (int i = 0; i < lockHolderTable.getColumnCount(); i++) {
lockHolderTable.getColumn(i).pack();
}
}
if (dbLotEntry.getBlockHoldersList() != null) {
for (BlockedHolders bean : dbLotEntry.getBlockHoldersList()) {
Map<String, String> map = new HashMap<String, String>();
map.put("0", String.valueOf(bean.getTran_index()));
map.put("1", bean.getGranted_mode());
map.put("2", String.valueOf(bean.getCount()));
map.put("3", String.valueOf(bean.getBlocked_mode()));
map.put("4", String.valueOf(bean.getStart_at()));
map.put("5", String.valueOf(bean.getWait_for_sec()));
blockedHolderListData.add(map);
}
blockedHolderTableViewer.refresh();
for (int i = 0; i < blockedHolderTable.getColumnCount(); i++) {
blockedHolderTable.getColumn(i).pack();
}
}
if (dbLotEntry.getLockWaitersList() != null) {
for (LockWaiters bean : dbLotEntry.getLockWaitersList()) {
Map<String, String> map = new HashMap<String, String>();
map.put("0", String.valueOf(bean.getTran_index()));
map.put("1", bean.getB_mode());
map.put("2", String.valueOf(bean.getStart_at()));
map.put("3", String.valueOf(bean.getWaitfornsec()));
lockWaiterListData.add(map);
}
lockWaiterTableViewer.refresh();
for (int i = 0; i < lockWaiterTable.getColumnCount(); i++) {
lockWaiterTable.getColumn(i).pack();
}
}
objectIdLabel.setText(Messages.bind(Messages.lblObjectId, dbLotEntry.getOid()));
objectTypeLabel.setText(Messages.bind(Messages.lblObjectType, dbLotEntry.getOb_type()));
}
Aggregations