Package org.eclipse.core.runtime

Examples of org.eclipse.core.runtime.IProgressMonitor.worked()


                        }

                        VirtualMachine vm= runnable.getVirtualMachine();
                        if (vm != null) {
                            DroolsDebugModel.newDebugTarget(launch, vm, renderDebugTarget(config.getClassToLaunch(), port), process, true, false, config.isResumeOnStartup());
                            subMonitor.worked(1);
                            subMonitor.done();
                        }
                        return;
                    } catch (InterruptedIOException e) {
                        checkErrorMessage(process);
View Full Code Here


      IContainer container = getContainer(sourceModule);

      IPath outputPath = getAbsolutePath(sourceModule);
      IPath[] generateResources = generateResources(moduleDeclaration, outputPath, container,
              sourceModule);
      monitor.worked(2);
      String defaultDescriptorLocation = RutaProjectUtils.getDefaultDescriptorLocation();
      IFolder folder = container.getProject().getFolder(defaultDescriptorLocation);
      for (IPath iPath : generateResources) {
        iPath = iPath.makeRelativeTo(folder.getLocation());
        IResource findMember = folder.findMember(iPath);
View Full Code Here

      }
      folder.refreshLocal(IResource.DEPTH_INFINITE, new SubProgressMonitor(monitor,
              generateResources.length));

      monitor.worked(1);
    } catch (ModelException e) {
      if (DLTKCore.DEBUG_PARSER) {
        e.printStackTrace();
      }
    } catch (CoreException e) {
View Full Code Here

            monitor.beginTask("Generate content provider...", 0);

            IFile file = (IFile) obj;
            try {
                monitor.subTask("Create source folder...");
                monitor.worked(1);

                IContainer container = file.getProject();

                final IFolder srcGenFolder = container.getFolder(new Path(ContentValues.SRC_GEN_PATH));
View Full Code Here

                String projectSrcPath = getSourceFolderPathFromClasspath(file.getProject().getFile(".classpath")
                        .getContents());
                String srcGenPath = file.getProject().getFolder(projectSrcPath).getLocation().toOSString();

                monitor.subTask("Generate content provider ...");
                monitor.worked(2);

                ACPGenLauncher.run(null, ecorePath, srcGenPath);

                file.getProject().refreshLocal(IProject.DEPTH_INFINITE, null);
            } catch (ParserConfigurationException e) {
View Full Code Here

                    } catch (CoreException e) {
                        recordError(e); // log error
                        return false;
                    }
                }
                subMonitor.worked(1);
                if (subMonitor.isCanceled()) {
                    throw new OperationCanceledException();
                }
            }
        } catch (CoreException e) {
View Full Code Here

     */
    public synchronized void communicateWork(String desc) throws OperationCanceledException {
        IProgressMonitor monitor = getMonitor();
        if (monitor != null) {
            monitor.setTaskName(desc);
            monitor.worked(1);
            checkCancelled();
        }
    }

    /**
 
View Full Code Here

    public IProgressMonitor getProgressMonitor() {
        if (progressMonitor == null) {
            final IProgressMonitor m = super.getProgressMonitor();
            progressMonitor = new IProgressMonitor() {
                public void worked(int work) {
                    m.worked(work);
                }

                public void subTask(String name) {
                    m.subTask(name);
                }
View Full Code Here

  }

  public void worked(int work) {
    IProgressMonitor monitor = getMonitor();
    if (monitor != null)
      monitor.worked(work);
    synchronized(this) {
      this.worked += work;
    }
  }
View Full Code Here

    try {
      monitor.beginTask(NLS.bind(CoreText.TagOperation_performingTagging,
          tag.getTag()), 3);

      ObjectId tagId = updateTagObject();
      monitor.worked(1);

      updateRepo(tagId);
      monitor.worked(1);

    } finally {
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.