viewer.addFilter(new ViewerFilter() {
@Override
public boolean select(Viewer viewer, Object parentElement, Object element) {
// The snapshots directory in Guvnor is read-only for Eclipse tools
if (element instanceof TreeObject) {
TreeObject o = (TreeObject)element;
return o.getFullPath().indexOf("/snapshots/") == -1; //$NON-NLS-1$
} else {
return true;
}
}
});