folder[0]= dialog.getCreatedFolder();
fFolder= dialog.getCreatedFolder();
    public static ILinkToQuery getDefaultLinkQuery(final Shell shell, final IJavaProject project, final IPath desiredOutputLocation) {        return new ILinkToQuery() {            final IFolder[] folder= {null};                        public boolean doQuery() {                final boolean[] isOK= {false};                Display.getDefault().syncExec(new Runnable() {                    public void run() {                        Shell sh= shell != null ? shell : JavaPlugin.getActiveWorkbenchShell();                        LinkFolderDialog dialog= new LinkFolderDialog(sh, project.getProject());                        isOK[0]= dialog.open() == Window.OK;                        if (isOK[0])                            folder[0]= dialog.getCreatedFolder();                    }                });                return isOK[0];            }            public IFolder getCreatedFolder() {                return folder[0];            }            public IOutputFolderQuery getOutputFolderQuery() {                return getDefaultFolderQuery(shell, desiredOutputLocation);            }                    };    }