IClasspathEntry entry= JavaCore.getClasspathVariable(curr); IPath path= entry != null ? entry.getPath() : Path.EMPTY; elements[i]= new CPVariableElement(curr, path);
IPath entryPath= JavaCore.getClasspathVariable(curr); elements[i]= new CPVariableElement(curr, entryPath);
	private String chooseVariable() {		String[] entries= JavaCore.getClasspathVariableNames();		int nEntries= entries.length;		CPVariableElement[] elements= new CPVariableElement[nEntries];		for (int i= 0; i < nEntries; i++) {			String curr= entries[i];			IClasspathEntry entry= JavaCore.getClasspathVariable(curr);			IPath path= entry != null ? entry.getPath() : Path.EMPTY;			elements[i]= new CPVariableElement(curr, path);		}			ElementListSelectionDialog dialog= new ElementListSelectionDialog(getShell(), new CPVariableElementLabelProvider(), false, true);		dialog.setTitle(JavaPlugin.getResourceString(DIALOG_CHOOSEVARIABLE + ".title"));		dialog.setMessage(JavaPlugin.getResourceString(DIALOG_CHOOSEVARIABLE + ".description"));		dialog.setEmptyListMessage(JavaPlugin.getResourceString(DIALOG_CHOOSEVARIABLE + ".empty"));		if (dialog.open(elements) == dialog.OK) {			CPVariableElement res= (CPVariableElement) dialog.getPrimaryResult();			return res.getName();		}		return null;	}