コード例 #1
0
 /** @generated */
 public boolean canExecute() {
   OnMessage container = (OnMessage) getElementToEdit();
   if (container.getActivity() != null) {
     return false;
   }
   return true;
 }
コード例 #2
0
  /** @generated */
  protected CommandResult doExecuteWithResult(IProgressMonitor monitor, IAdaptable info)
      throws ExecutionException {
    Reply newElement = BPELFactory.eINSTANCE.createReply();

    OnMessage owner = (OnMessage) getElementToEdit();
    owner.setActivity(newElement);

    doConfigure(newElement, monitor, info);

    ((CreateElementRequest) getRequest()).setNewElement(newElement);
    return CommandResult.newOKCommandResult(newElement);
  }