Examples of WorkspaceModifyOperation


Examples of org.eclipse.ui.actions.WorkspaceModifyOperation

                .newProjectDescription(newProjectHandle.getName());
        description.setLocation(newPath);
        addNatures(description);

        // create the new project operation
        WorkspaceModifyOperation op = new WorkspaceModifyOperation() {
            protected void execute(IProgressMonitor monitor)
                    throws CoreException {
                createProject(description, newProjectHandle, monitor);
            }
        };
View Full Code Here

Examples of org.eclipse.ui.actions.WorkspaceModifyOperation

              String packageName = process.getPackageName();
              if (packageName == null || packageName.trim().length() == 0 || "org.drools.bpmn2".equals(packageName)) {
                packageName = "org.jbpm";
              }
              final String pName = packageName;
                WorkspaceModifyOperation op = new WorkspaceModifyOperation() {
                    public void execute(final IProgressMonitor monitor)
                            throws CoreException {
                        try {
                            IFolder folder = file.getProject().getFolder("src/main/java");
                            IPackageFragmentRoot packageFragmentRoot = javaProject
View Full Code Here

Examples of org.eclipse.ui.actions.WorkspaceModifyOperation

                          task.getOutputParams().put(entry.getKey(), variableScope.findVariable(entry.getValue()).getType().getStringType());
                        }
                  }
                }
              }
                WorkspaceModifyOperation op = new WorkspaceModifyOperation() {
                    public void execute(final IProgressMonitor monitor)
                            throws CoreException {
                        try {
                            IFolder folder = file.getProject().getFolder("src/main/resources");
                          for (TaskDef task: tasks.values()) {
View Full Code Here

Examples of org.eclipse.ui.actions.WorkspaceModifyOperation

    saveOptions.put(XMLResource.OPTION_URI_HANDLER, new
        URIHandlerImpl.PlatformSchemeAware());

    // Do the work within an operation because this is a long running activity that modifies the workbench.
    //
    WorkspaceModifyOperation operation =
      new WorkspaceModifyOperation() {
        // This is the method that gets invoked when the operation runs.
        //
        @Override
        public void execute(IProgressMonitor monitor) {
          // Save the resources to the file system.
View Full Code Here

Examples of org.eclipse.ui.actions.WorkspaceModifyOperation

    }

    @Override
    public boolean performFinish() {

      IRunnableWithProgress op = new WorkspaceModifyOperation(null) {

        protected void execute(IProgressMonitor monitor)
            throws CoreException, InterruptedException {

          AbstractTransactionalCommand command = new AbstractTransactionalCommand(
View Full Code Here

Examples of org.eclipse.ui.actions.WorkspaceModifyOperation

    IWorkspaceRoot myWorkspaceRoot = workspace.getRoot();

    final IProject newProjectHandle = myWorkspaceRoot.getProject(projectName);
    final IProjectDescription description = workspace.newProjectDescription(projectName);

    WorkspaceModifyOperation operation = new WorkspaceModifyOperation() {
      protected void execute(IProgressMonitor monitor) throws CoreException {
        createProject(description, newProjectHandle, monitor);
      }
    };
View Full Code Here

Examples of org.eclipse.ui.actions.WorkspaceModifyOperation

                        workspace.newProjectDescription(newProjectHandle.
                        getName());
                description.setLocation(newPath);

                // create the new project operation
                WorkspaceModifyOperation op =
                        new WorkspaceModifyOperation() {
                            protected void execute(IProgressMonitor monitor)
                                    throws CoreException {
                                createProject(description, newProjectHandle,
                                        monitor);
                            }
View Full Code Here

Examples of org.eclipse.ui.actions.WorkspaceModifyOperation

     * @return The WorkspaceModifyOperation that will save the policy
     *         being edited.
     */
    protected WorkspaceModifyOperation
            createSaveOperation(final SaveCommand saveCommand) {
        WorkspaceModifyOperation op = new WorkspaceModifyOperation() {
            protected void execute(IProgressMonitor monitor)
                    throws CoreException,
                    InterruptedException {
                try {
                    monitor.beginTask("Editor.save.progress", 2000);
View Full Code Here

Examples of org.eclipse.ui.actions.WorkspaceModifyOperation

        if (!mainPage.useDefaults()) {
            description.setLocation(mainPage.getLocationPath());
        }
        description.setNatureIds(new String[]{ JavaCore.NATURE_ID });

        WorkspaceModifyOperation op = new WorkspaceModifyOperation() {
            @Override
            protected void execute(IProgressMonitor monitor) throws CoreException {
                try {
                    monitor.beginTask("", 3000);
                    newProject.create(description, new SubProgressMonitor(monitor, 1000));
View Full Code Here

Examples of org.eclipse.ui.actions.WorkspaceModifyOperation

    IWorkspace workspace = ResourcesPlugin.getWorkspace();
    IFile file = workspace.getRoot().getFile(filePath);
    final IEditorInput newInput = new FileEditorInput(file);

    WorkspaceModifyOperation op = new WorkspaceModifyOperation() {
      public void execute(final IProgressMonitor monitor) throws CoreException {
        getDocumentProvider().saveDocument(monitor, newInput,
                getDocumentProvider().getDocument(getEditorInput()), true);
      }
    };
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.