Package org.openbp.core.model.item.process

Examples of org.openbp.core.model.item.process.InitialNode


      int n = entries.size();
      for (int i = 0; i < n; ++i)
      {
        ProcessEntry entry = (ProcessEntry) entries.get(i);

        InitialNode initialNode = entry.getInitialNode();
        if (initialNode != null)
        {
          state.addSelectedQualifier(initialNode.getQualifier());
        }
      }
    }
    else
    {
View Full Code Here


        else
        {
          for (Iterator it = entryList.iterator(); it.hasNext();)
          {
            ProcessEntry entry = (ProcessEntry) it.next();
            InitialNode node = entry.getInitialNode();
            if (!initialNodes.contains(node))
            {
              it.remove();
            }
          }

          if (entryList.size() == 0)
          {
            entryList = null;
          }
        }
      }
      else
      {
        if (initialNodes != null)
        {
          entryList = new ArrayList();
        }
      }

      // Now add all new initial nodes
      if (initialNodes != null && entryList != null)
      {
        int n = initialNodes.size();
        for (int i = 0; i < n; ++i)
        {
          InitialNode node = (InitialNode) initialNodes.get(i);

          if (!containsInitialNode(entryList, node))
          {
            ProcessEntry entry = new ProcessEntry();
            entry.setModel(settings.getModel());
            entry.setInitialNode(node);
            entry.setName(node.getName());
            entry.setDisplayName(node.getDisplayName());
            entryList.add(entry);
          }
        }
      }
View Full Code Here

    if (!super.validateObject(editedObject, pb))
    {
      return false;
    }

    InitialNode editedNode = (InitialNode) editedObject;
    if (editedNode.isDefaultEntry())
    {
      ProcessItem process = editedNode.getProcess();

      InitialNode currentDefaultInitialNode = process.getDefaultInitialNode();
      if (currentDefaultInitialNode != editedNode && currentDefaultInitialNode != pb.getObject() && currentDefaultInitialNode != pb.getOriginalObject())
      {
        currentDefaultInitialNode.setDefaultEntry(false);
      }
    }

    return true;
  }
View Full Code Here

   * @return The new node figure
   */
  public static NodeFigure createInitialNodeFromSocket(SocketFigure patternSocketFigure)
  {
    // Create a new node
    InitialNode node = ProcessElementFactory.getInstance().createStandardInitialNode();

    // Create the corresponding figure, add it to the process and return it
    return createNodeFromSocket(node, patternSocketFigure, 100);
  }
View Full Code Here

   */
  public void setInitialPosition(TokenContext context, String startRef, Map inputParamValues)
  {
    NodeSocket startSocket = getEngine().resolveSocketRef(startRef, context.getCurrentSocket(), context, true);

    InitialNode initialNode = (InitialNode) startSocket.getNode();
    if (initialNode.getEntryScope() != InitialNode.SCOPE_PUBLIC)
    {
      String msg = LogUtil.error(getClass(), "Node $0 is not a public initial node (start node reference: $1). [{2}]", initialNode.getQualifier(), startRef, context);
      throw new ModelException("NoPublicInitialNode", msg);
    }
    context.setCurrentSocket(startSocket);

    if (context.getExecutingModel() == null)
View Full Code Here

  implements Finder
{
  public List findModelObjectInModel(ModelObject mo, Model model)
  {
    List foundReferences = new ArrayList();
    InitialNode entry = (InitialNode) mo;
    ProcessItem process = entry.getProcess();
    Iterator modelProcess = model.getItems(ItemTypes.PROCESS);
    while (modelProcess.hasNext())
    {
      ProcessItem pi = (ProcessItem) modelProcess.next();
      foundReferences.addAll(findInProcess(process, entry, pi));
View Full Code Here

TOP

Related Classes of org.openbp.core.model.item.process.InitialNode

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.