use of com.cubrid.cubridmanager.ui.broker.editor.ApplyServerLabelProvider in project cubrid-manager by CUBRID.
the class BrokerSatusTablePart method createAsTable.
/**
* Create app server table
*
* @param comp the parent composite
* @return TableViewer
*
*/
public TableViewer createAsTable(Composite comp) {
Composite asComposite = new Composite(comp, SWT.NONE);
GridData gdAs = new GridData(SWT.FILL, SWT.FILL, true, true);
asComposite.setLayoutData(gdAs);
asComposite.setLayout(new GridLayout());
TableViewer asTableViewer = new TableViewer(asComposite, SWT.FULL_SELECTION | SWT.NO_SCROLL | SWT.V_SCROLL | SWT.BORDER);
Table asTable = asTableViewer.getTable();
asTable.setHeaderVisible(true);
asTable.setLinesVisible(true);
asTable.setLayoutData(gdAs);
TableLayout asLayout = new TableLayout();
setAsLayout(asLayout);
asTable.setLayout(asLayout);
TableColumn tblColumn = new TableColumn(asTable, SWT.CENTER);
tblColumn.setText(Messages.tblAsId);
tblColumn.setToolTipText(Messages.tblAsId);
tblColumn = new TableColumn(asTable, SWT.CENTER);
tblColumn.setText(Messages.tblAsProcess);
tblColumn.setToolTipText(Messages.tblAsProcess);
tblColumn = new TableColumn(asTable, SWT.CENTER);
tblColumn.setText(Messages.tblAsQps);
tblColumn.setToolTipText(Messages.tblAsQps);
tblColumn = new TableColumn(asTable, SWT.CENTER);
tblColumn.setText(Messages.tblAsLqs);
tblColumn.setToolTipText(Messages.tblAsLqs);
tblColumn = new TableColumn(asTable, SWT.CENTER);
tblColumn.setText(Messages.tblAsPort);
tblColumn.setToolTipText(Messages.tblAsPort);
tblColumn = new TableColumn(asTable, SWT.CENTER);
tblColumn.setText(Messages.tblAsSize);
tblColumn.setToolTipText(Messages.tblAsSize);
tblColumn = new TableColumn(asTable, SWT.CENTER);
tblColumn.setText(Messages.tblAsStatus);
tblColumn.setToolTipText(Messages.tblAsStatus);
tblColumn = new TableColumn(asTable, SWT.CENTER);
tblColumn.setText(Messages.tblAsDb);
tblColumn.setToolTipText(Messages.tblAsDb);
tblColumn = new TableColumn(asTable, SWT.CENTER);
tblColumn.setText(Messages.tblAsHost);
tblColumn.setToolTipText(Messages.tblAsHost);
tblColumn = new TableColumn(asTable, SWT.CENTER);
tblColumn.setText(Messages.tblAsLastAccess);
tblColumn.setToolTipText(Messages.tblAsLastAccess);
tblColumn = new TableColumn(asTable, SWT.CENTER);
tblColumn.setText(Messages.tblAsLct);
tblColumn.setToolTipText(Messages.tblAsLct);
tblColumn = new TableColumn(asTable, SWT.CENTER);
tblColumn.setText(Messages.tblAsClientIp);
tblColumn.setToolTipText(Messages.tblAsClientIp);
tblColumn = new TableColumn(asTable, SWT.CENTER);
tblColumn.setText(Messages.tblAsCur);
tblColumn.setToolTipText(Messages.tblAsCur);
asTableViewer.setContentProvider(new ApplyServerContentProvider());
asTableViewer.setLabelProvider(new ApplyServerLabelProvider());
asTableViewer.setInput(asinfoLst);
return asTableViewer;
}
Aggregations