Examples of IIf


Examples of org.springframework.ide.eclipse.webflow.core.model.IIf

    Node target = (Node) map.get(getTarget());
    Edge e = null;
    if (target.data != null && target.data instanceof AbstractStatePart) {
      IState startState = ((IWebflowState) ((AbstractStatePart) target.data)
          .getState().getElementParent()).getStartState();
      IIf sourceState = (IIf) ((AbstractStatePart) source.data)
          .getModel();
      IState targetState = ((AbstractStatePart) target.data).getState();
      if (startState.getId().equals(targetState.getId())) {
        e = new Edge(this, target, source);
      }
View Full Code Here

Examples of org.springframework.ide.eclipse.webflow.core.model.IIf

  /**
   * @param child
   * @return
   */
  protected Command createAddIfCommand(EditPart child) {
    IIf activity = (IIf) child.getModel();
    AddIfCommand add = new AddIfCommand();
    add.setParent((IDecisionState) getHost().getModel());
    add.setChild(activity);
    return add;
  }
View Full Code Here

Examples of org.springframework.ide.eclipse.webflow.core.model.IIf

                    command.add(createDeletePropertyCommand(childModel));
                    command.add(createCreatePropertyCommand(childModel, index));
                }
                else if (child.getModel() instanceof IIf
                        && getHost().getModel() instanceof IDecisionState) {
                    IIf childModel = (IIf) child.getModel();
                    command.add(createDeleteIfCommand(childModel));
                    command.add(createCreateIfCommand(childModel, index));
                }
                else if ((child.getModel() instanceof IInputMapper || child.getModel() instanceof IOutputMapper)
                        && getHost().getModel() instanceof IAttributeMapper) {
View Full Code Here

Examples of org.springframework.ide.eclipse.webflow.core.model.IIf

      buf.append(property.getName());
      buf.append("=");
      buf.append(property.getValue());
    }
    else if (element instanceof IIf) {
      IIf theIf = (IIf) element;
      // int index = ((IDecisionState)
      // theIf.getElementParent()).getIfs().indexOf(theIf) + 1;
      // buf.append(index);
      // buf.append(": ");
      buf.append(theIf.getTest());
    }
    else if (element instanceof IBean) {
      IBean bean = (IBean) element;
      buf.append(bean.getElementName());
      if (bean.getClassName() != null) {
View Full Code Here

Examples of org.springframework.ide.eclipse.webflow.core.model.IIf

    }

    Iterator iter = ((IDecisionState) getModel()).getIfs().iterator();
    int j = 0;
    while (iter.hasNext()) {
      IIf theIf = (IIf) iter.next();
      if (theIf.getThenTransition() != null
          && theIf.getThenTransition().getToState() != null) {
        // insert dummy edges for layouting
        Edge e1 = new Edge((Node) map.get(this), getNode(theIf
            .getThenTransition().getToState(), map));

        // e1.weight = 5;
        graph.edges.add(e1);
        map.put(this.toString() + (j++), e1);
      }
      if (theIf.getElseTransition() != null
          && theIf.getElseTransition().getToState() != null) {
        Edge e2 = new Edge((Node) map.get(this), getNode(theIf
            .getElseTransition().getToState(), map));
        // e2.weight = 5;
        graph.edges.add(e2);
        map.put(this.toString() + (j++), e2);
      }
View Full Code Here

Examples of org.springframework.ide.eclipse.webflow.core.model.IIf

   * @see org.eclipse.gef.editparts.AbstractGraphicalEditPart#getModelSourceConnections()
   */
  protected List getModelSourceConnections() {
    if (getModel() instanceof IIf) {
      List<IWebflowModelElement> sourceConnections = new ArrayList<IWebflowModelElement>();
      IIf theIf = (IIf) getModel();
      if (theIf.getThenTransition() != null
          && theIf.getThenTransition().getToState() != null) {
        sourceConnections.add(theIf.getThenTransition());
      }
      if (theIf.getElseTransition() != null
          && theIf.getElseTransition().getToState() != null) {
        sourceConnections.add(theIf.getElseTransition());
      }
      return sourceConnections;
    }
    else {
      return Collections.EMPTY_LIST;
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.