Package org.eclipse.core.resources

Examples of org.eclipse.core.resources.IProject.refreshLocal()


         
          FacetManager.installFacets(project, PHPVersion.PHP5_4, monitor);
         
          monitor.worked(1);
         
          project.refreshLocal(IResource.DEPTH_INFINITE, monitor);
          monitor.worked(2);
         
        } catch (CoreException e) {
          Logger.logException(e);
        } catch (IOException e) {
View Full Code Here


            public void done(IJobChangeEvent event) {
              if (exportRarJob.getError() != null) {
                PlatformUI.getWorkbench().getDisplay().syncExec(new Runnable() {
                  public void run() {
                    try {
                      project.refreshLocal(IResource.DEPTH_INFINITE, new NullProgressMonitor());
                    } catch (CoreException e) {
                      MessageDialog.openError(shell, "Error", "Error refreshing workspace.");
                    }
                    MessageDialog.openError(shell, "Error", exportRarJob.getError());
                  }
View Full Code Here

        return Status.CANCEL_STATUS;

      monitor.setTaskName("Cleanup ...");
      cdkProjectJarFile.delete(true, new SubProgressMonitor(monitor, 5, SubProgressMonitor.PREPEND_MAIN_LABEL_TO_SUBTASK));
      ResourceUtils.deleteFile(cdkProjectJarLocation.toFile());
      project.refreshLocal(IResource.DEPTH_INFINITE, monitor);
    } catch (InvocationTargetException e) {
      errorMessage = e.getMessage();
    } catch (InterruptedException e) {
      errorMessage = e.getMessage();
    } catch (CoreException e) {
View Full Code Here

      public void run(IProgressMonitor runInWorkspaceMonitor) throws CoreException {
        // workspaceRunnableProject.refreshLocal(IResource.DEPTH_INFINITE,
        // runInWorkspaceMonitor);
        // MS: touch a build/.version file to notify rapid turnaround of
        // changes
        workspaceRunnableProject.refreshLocal(IResource.DEPTH_ONE, runInWorkspaceMonitor);
        IFolder buildFolder = workspaceRunnableProject.getFolder(IBuildAdapter.FILE_NAME_BUILD);
        if (buildFolder.exists()) {
          buildFolder.refreshLocal(IResource.DEPTH_ONE, runInWorkspaceMonitor);
          try {
            IFile buildVersion = buildFolder.getFile(".version");
View Full Code Here

            }
          }
        });
       
        try {
          newProjectHandle.refreshLocal(1, monitor);
        } catch (CoreException e) {
          throw new InvocationTargetException(e);
        }
       
        monitor.done();
View Full Code Here

        srcLocFile.mkdir();

        assertTrue(!project.exists());
        project.create(monitor);
        project.open(monitor);
        project.refreshLocal(IResource.DEPTH_INFINITE, monitor);
        IJobManager jobManager = Job.getJobManager();
        jobManager.resume();
        final PythonNature nature = (PythonNature) PythonNature.addNature(project, null, null, null, null, null, null);
        assertTrue(nature != null);
View Full Code Here

        String contents = "";
        String newContents = "class Foo(object):\n    pass";

        myFile.create(new ByteArrayInputStream(contents.getBytes()), true, monitor);
        project.refreshLocal(IResource.DEPTH_INFINITE, monitor);
        try {
            editor = (PyEdit) PyOpenEditor.doOpenEditor(myFile);
            editor.getDocument().set(newContents);
            editor.doSave(monitor);
        } finally {
View Full Code Here

        folder.create(true, true, null);

        IFile file2 = folder.getFile("my_file.py");
        file2.create(new ByteArrayInputStream("".getBytes()), true, monitor);

        project.refreshLocal(IResource.DEPTH_INFINITE, monitor);

        PyEdit editor2 = null;
        PyEdit editor = null;
        try {
            editor = (PyEdit) PyOpenEditor.doOpenEditor(myFile);
View Full Code Here

    SWTBotTree tree = getOrOpenView().bot().tree();
    refreshAndWait();

    IProject project1 = ResourcesPlugin.getWorkspace().getRoot().getProject(PROJ1);
    // Make sure that the refresh doesn't happen on delete and cause a timeout
    project1.refreshLocal(IResource.DEPTH_INFINITE, null);

    SWTBotTreeItem folder = findWorkdirNode(tree, PROJ1, FOLDER);
    folder.getNode(FILE1).select();

    ContextMenuHelper.clickContextMenu(tree,
View Full Code Here

            // the .git directory without us stopping them.
            // (Half lie, we should optimize so we do not
            // refresh when the .git is not within the project)
            //
            if (!gitDir.toString().contains("..")) //$NON-NLS-1$
              project.refreshLocal(IResource.DEPTH_ONE,
                  new NullProgressMonitor());
          }
          util.addConfiguredRepository(gitDir);
        } catch (IOException e1) {
          String msg = NLS
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.