Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
Copyright (c) 2007, 2008 IBM Corporation and others. All rights reserved. This program and the accompanying materials are made available under the terms of the Eclipse Public License v1.0 which accompanies this distribution, and is available at http://www.eclipse.org/legal/epl-v10.html Contributors: IBM Corporation - initial API and implementation /
package org.eclipse.equinox.internal.security.ui.wizard;
import  org.eclipse.swt.SWT;
import  org.eclipse.swt.layout.GridData;
import  org.eclipse.swt.layout.GridLayout;
import  org.eclipse.swt.widgets.*;
public class CertificateViewer {
	private Composite composite;
	public CertificateViewer(Composite parent) {
		 = new Composite(parent, SWT.None);
		.setLayout(new GridLayout());
		 = new TableViewer(, SWT.H_SCROLL | SWT.V_SCROLL | SWT.BORDER);
		Table table = .getTable();
		table.setHeaderVisible(true);
		GridData tableData = new GridData(GridData.HORIZONTAL_ALIGN_FILL | GridData.GRAB_HORIZONTAL);
		table.setLayoutData(tableData);
		TableColumn propertyCol = new TableColumn(table, SWT.LEFT);
		propertyCol.setText(.);
		propertyCol.setWidth(200);
		TableColumn valueCol = new TableColumn(table, SWT.LEFT);
		valueCol.setWidth(300);
	}
	public void setCertificate(Certificate certificate) {
		.setInput(certificate);
	}
New to GrepCode? Check out our FAQ X