Source:
<code>public void createControl(Composite parent) { Composite container = new Composite(parent, SWT.NULL); setControl(container); container.setLayout(new FillLayout(SWT.VERTICAL)); tableViewer = new TableViewer(container, SWT.BORDER | SWT.FULL_SELECTION); tableViewer.setContentProvider(ArrayContentProvider.getInstance()); table = tableViewer.getTable(); table.setLinesVisible(true); table.setHeaderVisible(true); TableViewerColumn tableViewerColumn = new TableViewerColumn(tableViewer, SWT.NONE); TableColumn tblclmnName = tableViewerColumn.getColumn(); tblclmnName.setWidth(193); tblclmnName.setText("Name"); TableViewerColumn tableViewerColumn_1 = new TableViewerColumn(tableViewer, SWT.NONE); TableColumn tblclmnTags = tableViewerColumn_1.getColumn(); tblclmnTags.setWidth(409); tblclmnTags.setText("Tags"); tableViewerColumn.setLabelProvider(new ColumnLabelProvider() { @Override public String getText(Object element) { Archetype a = (Archetype) element; return a.getName(); } }); tableViewerColumn_1.setLabelProvider(new ColumnLabelProvider() { @Override public String getText(Object element) { Archetype a = (Archetype) element; List<Tag> tags = a.getTags(); String s = ""; if (tags != null) { for (int i = 0; i < tags.size(); i++) { Tag t = tags.get(i); <START> s += t.getName(); <END> if (i < tags.size() - 1) { s += ", "; } } } return s; } }); tableViewer.addSelectionChangedListener(new ISelectionChangedListener() { @Override public void selectionChanged(SelectionChangedEvent event) { IStructuredSelection selection = (IStructuredSelection) event.getSelection(); Archetype archetypeSelected = (Archetype) selection.getFirstElement(); projectConfigModel.seArchetypeSelected(archetypeSelected); System.out.println("selected archetype: " + archetypeSelected); } }); }</code><technical_language>StringBuilder efficient compare concatenation. compiler wont do optimisation loops</technical_language>

Target:
public void createControl(Composite parent) { Composite container = new Composite(parent, SWT.NULL); setControl(container); container.setLayout(new RowLayout(SWT.VERTICAL)); tableViewer = new TableViewer(container, SWT.BORDER | SWT.FULL_SELECTION); tableViewer.setContentProvider(ArrayContentProvider.getInstance()); table = tableViewer.getTable(); table.setLayoutData(new RowData(567, 259)); table.setLinesVisible(true); table.setHeaderVisible(true); TableViewerColumn tableViewerColumn = new TableViewerColumn(tableViewer, SWT.NONE); TableColumn tblclmnName = tableViewerColumn.getColumn(); tblclmnName.setWidth(193); tblclmnName.setText("Name"); TableViewerColumn tableViewerColumnTag = new TableViewerColumn(tableViewer, SWT.NONE); TableColumn tblclmnTags = tableViewerColumnTag.getColumn(); tblclmnTags.setWidth(409); tblclmnTags.setText("Tags"); fetchMonitor = new ProgressMonitor(container); tableViewerColumn.setLabelProvider(new ColumnLabelProvider() { @Override public String getText(Object element) { Archetype a = (Archetype) element; return a.getName(); } }); tableViewerColumnTag.setLabelProvider(new ColumnLabelProvider() { @Override public String getText(Object element) { Archetype a = (Archetype) element; List<Tag> tags = a.getTags(); StringBuffer sb = new StringBuffer(); if (tags != null) { for (int i = 0; i < tags.size(); i++) { Tag t = tags.get(i); sb.append(t.getName()); if (i < tags.size() - 1) { sb.append(", "); } } } return sb.toString(); } }); tableViewer.addSelectionChangedListener(new ISelectionChangedListener() { @Override public void selectionChanged(SelectionChangedEvent event) { IStructuredSelection selection = (IStructuredSelection) event.getSelection(); Archetype archetypeSelected = (Archetype) selection.getFirstElement(); projectConfigModel.seArchetypeSelected(archetypeSelected); setPageComplete(true); } }); }