Package fd2.diagram.expressions

Examples of fd2.diagram.expressions.Fd2OCLFactory$Expression


   */
  protected boolean canReorientTarget() {
    if (!(oldEnd instanceof BaseFeatureNode && newEnd instanceof BaseFeatureNode)) {
      return false;
    }
    BaseFeatureNode source = getLink().getSourceFeature();
    if (!(getLink().eContainer() instanceof Diagram)) {
      return false;
    }
    Diagram container = (Diagram) getLink().eContainer();
    return Fd2BaseItemSemanticEditPolicy.LinkConstraints
View Full Code Here


  /**
   * @generated
   */
  protected CommandResult doExecuteWithResult(IProgressMonitor monitor,
      IAdaptable info) throws ExecutionException {
    CaseOrRelation newElement = Fd2Factory.eINSTANCE.createCaseOrRelation();

    BaseFeatureNode owner = (BaseFeatureNode) getElementToEdit();
    owner.getChildRelations().add(newElement);

    Fd2ElementTypes.init_CaseOrRelation_3002(newElement);
View Full Code Here

   * @generated
   */
  @Override
  public String getText(Object object)
  {
    CaseOrRelation caseOrRelation = (CaseOrRelation)object;
    return getString("_UI_CaseOrRelation_type") + " " + caseOrRelation.getLowerBound();
  }
View Full Code Here

        Messages.Fd2DiagramEditorUtil_CreateDiagramCommandLabel,
        Collections.EMPTY_LIST) {
      protected CommandResult doExecuteWithResult(
          IProgressMonitor monitor, IAdaptable info)
          throws ExecutionException {
        Diagram model = createInitialModel();
        attachModelToResource(model, modelResource);

        org.eclipse.gmf.runtime.notation.Diagram diagram = ViewService
            .createDiagram(model, DiagramEditPart.MODEL_ID,
                Fd2DiagramEditorPlugin.DIAGRAM_PREFERENCES_HINT);
View Full Code Here

   */
  protected CommandResult doExecuteWithResult(IProgressMonitor monitor,
      IAdaptable info) throws ExecutionException {
    FeatureNode newElement = Fd2Factory.eINSTANCE.createFeatureNode();

    Diagram owner = (Diagram) getElementToEdit();
    owner.getDiagramElements().add(newElement);

    doConfigure(newElement, monitor, info);

    ((CreateElementRequest) getRequest()).setNewElement(newElement);
    return CommandResult.newOKCommandResult(newElement);
View Full Code Here

    }
    BaseFeatureNode target = getLink().getTargetFeature();
    if (!(getLink().eContainer() instanceof Diagram)) {
      return false;
    }
    Diagram container = (Diagram) getLink().eContainer();
    return Fd2BaseItemSemanticEditPolicy.LinkConstraints
        .canExistExcludesRelation_4010(container, getNewSource(),
            target);
  }
View Full Code Here

   */
  protected CommandResult doExecuteWithResult(IProgressMonitor monitor,
      IAdaptable info) throws ExecutionException {
    FeatureNode newElement = Fd2Factory.eINSTANCE.createFeatureNode();

    Diagram owner = (Diagram) getElementToEdit();
    owner.getDiagramElements().add(newElement);

    doConfigure(newElement, monitor, info);

    ((CreateElementRequest) getRequest()).setNewElement(newElement);
    return CommandResult.newOKCommandResult(newElement);
View Full Code Here

    }
    BaseFeatureNode source = getLink().getSourceFeature();
    if (!(getLink().eContainer() instanceof Diagram)) {
      return false;
    }
    Diagram container = (Diagram) getLink().eContainer();
    return Fd2BaseItemSemanticEditPolicy.LinkConstraints
        .canExistExcludesRelation_4010(container, source,
            getNewTarget());
  }
View Full Code Here

                }
              }

            }
          } else if (DGelem instanceof ExcludesRelation) {
            ExcludesRelation excludeRelation = (ExcludesRelation) DGelem;
            if (excludeRelation.getSourceFeature().getName()
                .contentEquals(AE.getFeatureElement())) {
             
              String excludesElementName = excludeRelation.getTargetFeature().getName();
              AE.addExcludesRelation(excludesElementName);
             
              for (AssociatedElement parentSearchAE : DG
                  .getDiagramAssociations()
                  .getElements()) {
View Full Code Here

    if (!canExecute()) {
      throw new ExecutionException(
          "Invalid arguments in create link command"); //$NON-NLS-1$
    }

    ExcludesRelation newElement = Fd2Factory.eINSTANCE
        .createExcludesRelation();
    getContainer().getDiagramElements().add(newElement);
    newElement.setSourceFeature(getSource());
    newElement.setTargetFeature(getTarget());
    doConfigure(newElement, monitor, info);
    ((CreateElementRequest) getRequest()).setNewElement(newElement);
    return CommandResult.newOKCommandResult(newElement);

  }
View Full Code Here

TOP

Related Classes of fd2.diagram.expressions.Fd2OCLFactory$Expression

Copyright © 2018 www.massapicom. 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.