/** @see AbstractIOAdvisor#prepareProvider(IOProvider) */
  @Override
  public void prepareProvider(AlignmentWriter provider) {
    super.prepareProvider(provider);

    AlignmentService as = getService(AlignmentService.class);
    provider.setAlignment(as.getAlignment());

    SchemaService ss = getService(SchemaService.class);
    provider.setSourceSchema(ss.getSchemas(SchemaSpaceID.SOURCE));
    provider.setTargetSchema(ss.getSchemas(SchemaSpaceID.TARGET));
  }
Esempio n. 2
0
  /** @see org.eclipse.core.commands.IHandler#execute(org.eclipse.core.commands.ExecutionEvent) */
  @Override
  public Object execute(ExecutionEvent event) throws ExecutionException {
    if (MessageDialog.openQuestion(
        HandlerUtil.getActiveShell(event),
        "Delete cells",
        "Do you really want to delete all cells?")) {
      AlignmentService as = PlatformUI.getWorkbench().getService(AlignmentService.class);
      as.clean();
    }

    return null;
  }