Examples of execute()


Examples of org.eclipse.emf.edit.command.RemoveCommand.execute()

   */
  private boolean handleRemoveMetaInfFile( final KeyValuePair value ) {
    if ( MessageDialog.openConfirm( getSite().getShell(), "Confirm delete", "Would really like to remove the selected META-INF file" ) ) {
      RemoveCommand cmd = new RemoveCommand( editingDomain, getTask().getFiles(), value );
      if ( cmd.canExecute() ) {
        cmd.execute();
        return true;
      }
    }
    return false;
  }
View Full Code Here

Examples of org.eclipse.emf.edit.command.SetCommand.execute()

                if ( template != null ) {
                  if ( getTask().getDeploy().getTemplate() == null ) {
                    Command cmd = new SetCommand( editingDomain, getTask().getDeploy(), DEPLOY__TEMPLATE, ParametersFactory.eINSTANCE
                        .createTemplate() );
                    if ( cmd.canExecute() ) {
                      cmd.execute();
                    }
                  }
                  Command cmd = new SetCommand( editingDomain, getTask().getDeploy().getTemplate(), TEMPLATE__FILE, template );
                  if ( cmd.canExecute() ) {
                    cmd.execute();
View Full Code Here

Examples of org.eclipse.emf.query.statements.SELECT.execute()

              exclude);

          SELECT statement = new SELECT(new FROM(cataloguge
              .getCatalogueProperties()), new WHERE(condition0
              .AND(condition1.OR(condition2.OR(condition3)))));
          for (Object object : statement.execute()) {
            addTreeItem((TechnicalProperty) object);

          }

          matchesMap.putAll(condition1.getHits());
View Full Code Here

Examples of org.eclipse.emf.workspace.AbstractEMFOperation.execute()

                   
                    return Status.OK_STATUS;
                }
            };
            try {
                operation.execute(new NullProgressMonitor(), null);
            }
            catch (Exception e) {
                throw new RuntimeException(e.getCause());
            }
        }
View Full Code Here

Examples of org.eclipse.gef.commands.Command.execute()

  @Override
  public void run() {
    Command cmd = createCopyCommand(getSelectedObjects());
    if (cmd != null && cmd.canExecute()) {
      cmd.execute();
      // force an updateActions for paste command
      if (getWorkbenchPart().getSite().getPage().getActivePart() instanceof SarosWhiteboardView) {
        ((SarosWhiteboardView) getWorkbenchPart().getSite().getPage()
            .getActivePart()).getEditor().updateSelectionActions();
      } else if (getWorkbenchPart().getSite().getPage().getActivePart() instanceof WhiteboardEditor) {
View Full Code Here

Examples of org.eclipse.gef.commands.CommandStack.execute()

        if (targetPart instanceof GraphicalEditor) {
            commandStack = (CommandStack) ((GraphicalEditor) targetPart).getAdapter(CommandStack.class);
        } else {
            commandStack = ((OutlineViewer) ((ContentOutline) targetPart).getCurrentPage()).getCommandStack();
        }
        commandStack.execute(command);
    }
   
    protected IEditorPart getActiveEditor() {
        return targetPart.getSite().getPage().getActiveEditor();
    }
View Full Code Here

Examples of org.eclipse.gef.commands.CompoundCommand.execute()

    compoundCommand.add(createCmd);
    DeleteCommand cleanupCommand = new DeleteCommand();
    cleanupCommand.setParent(activeDiagram);
    cleanupCommand.setChild(child);
    compoundCommand.add(cleanupCommand);
    compoundCommand.execute();   
  }
 
  @Override
  public void undo(){
    redo();
View Full Code Here

Examples of org.eclipse.gmf.runtime.common.core.command.ICommand.execute()

      }

    };
   
    try {
      command.execute(new NullProgressMonitor(), null);
    } catch (ExecutionException e) {
      throw new RuntimeException(e.getMessage(), e);
    }
   
  }
View Full Code Here

Examples of org.eclipse.gmf.runtime.diagram.core.commands.DeleteCommand.execute()

      // edit part?
      IGraphicalEditPart contained = elementContainedWithin(selected, diagramEditPart);
      if (contained != null) {
        // it is: delete the node from the current display               
        DeleteCommand command2 = new DeleteCommand(editingDomain, contained.getPrimaryView());
        command2.execute(monitor, info);
      }
    }
  }

  /**
 
View Full Code Here

Examples of org.eclipse.gmf.runtime.emf.commands.core.command.AbstractTransactionalCommand.execute()

      }

    };
   
    try {
      command.execute(new NullProgressMonitor(), null);
    } catch (ExecutionException e) {
      throw new RuntimeException(e.getMessage(), e);
    }
   
  }
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.