Examples of physicalEntity


Examples of org.biopax.paxtools.model.level2.physicalEntity

    for (SimpleInteraction simpleInt : simpleInts)
    {
      if (simpleInt.getSource() instanceof physicalEntity &&
        simpleInt.getTarget() instanceof physicalEntity)
      {
        physicalEntity source = (physicalEntity) simpleInt.getSource();
        physicalEntity target = (physicalEntity) simpleInt.getTarget();

        if (!map.containsKey(source))
        {
          map.put(source, new SIFNode(this, source));
        }
        if (!map.containsKey(target))
        {
          map.put(target, new SIFNode(this, target));
        }
        SIFNode sourceNode = map.get(source);
        SIFNode targetNode = map.get(target);

        String id = source.getRDFId() + " - " + target.getRDFId();

        if (encountered.contains(id))
        {
          continue;
        }

        new SIFEdge(sourceNode, targetNode, simpleInt.getType());

        encountered.add(id);

        if (!simpleInt.getType().isDirected())
        {
          encountered.add(target.getRDFId() + " - " + source.getRDFId());
        }
      }
    }
  }
View Full Code Here

Examples of org.biopax.paxtools.model.level2.physicalEntity

          {
            Node corresponding = (Node) actor.getLabel(BioPAXGraph.EXCISED_FROM);

            if (corresponding instanceof EntityAssociated)
            {
              physicalEntity entity = ((EntityAssociated) corresponding).getEntity();
              List<Node> nodeList = entityToNodeMap.get(entity);

              for (Node node : nodeList)
              {
                targets.add(node);
View Full Code Here

Examples of org.biopax.paxtools.model.level2.physicalEntity

     * Method to run query
     */
    public Set<NodePair> run()
    {
      BFS bfs = null;
      physicalEntity entity;
     
      //for every node
      for (Object obj : allNodes)
    {
        //get entity of Node
View Full Code Here

Examples of org.biopax.paxtools.model.level2.physicalEntity

        for (String selected : selectionResult)
        {
          //search among all addedEntities
          for (int j = 0 ; j < addedEntities.size() ; j++)
          {
            physicalEntity entity = addedEntities.get(j);
           
            //if corresponding entity is found
            if (selected != null &&
              selected.equals(getKeyNAME(entity)))
            {
View Full Code Here

Examples of org.biopax.paxtools.model.level2.physicalEntity

        for (String selected : selectionResult)
        {
          //search among all addedEntities
          for (int j = 0 ; j < addedEntities.size() ; j++)
          {
            physicalEntity entity = addedEntities.get(j);
           
            //if corresponding entity is found
            if (selected != null &&
              selected.equals(getKeyNAME(entity)))
            {
View Full Code Here

Examples of org.biopax.paxtools.model.level2.physicalEntity

                for (String selected : selectionResult)
                {
                    //search among all addedEntities
                    for (int j = 0 ; j < addedEntities.size() ; j++)
                    {
                        physicalEntity entity = addedEntities.get(j);

                        //if corresponding entity is found
                        if (selected != null &&
                            selected.equals(getKeyNAME(entity)))
                        {
View Full Code Here

Examples of org.biopax.paxtools.model.level2.physicalEntity

                for (String selected : selectionResult)
                {
                    //search among all sourceAddedEntities
                    for (int j = 0 ; j < sourceAddedEntities.size() ; j++)
                    {
                        physicalEntity entity = sourceAddedEntities.get(j);

                        //if corresponding entity is found
                        if (selected != null &&
                            selected.equals(getKeyNAME(entity)))
                        {
                            //remove entity from sourceAddedEntities ArrayList
                            sourceAddedEntities.remove(j);

                            //remove entity keyName from source entity list
                            entityList.remove(selected);
                        }
                    }
               }
            }
        });

        //Target add button

        targetAddButton = new Button(shell, SWT.NONE);
        targetAddButton.setText("Add...");
        gridData = new GridData(GridData.END, GridData.BEGINNING, true, false);
        gridData.minimumWidth = 100;
        gridData.horizontalIndent = 5;
        targetAddButton.setLayoutData(gridData);
        targetAddButton.addSelectionListener(new SelectionAdapter()
        {
            public void widgetSelected(SelectionEvent arg0)
            {
                //new addEntityDialog
                AddEntityDialog addEntity =
                    new AddEntityDialog(new Shell(), allEntities);

                //open dialog
                boolean addPressed = addEntity.open();

                //if add button is pressed
                if (addPressed)
                {
                    //for each selected entity
                    for (physicalEntity entity : addEntity.getSelectedEntities())
                    {
                        //check if entity has been added before
                        if (!previouslyAdded(entity, targetAddedEntities))
                        {
                            //add entity keyName to target entity list
                            targetEntityList.add(getKeyNAME(entity));

                            //add entity to targetAddedEntities ArrayList
                            targetAddedEntities.add(entity);
                        }
                    }
                }
            }
        });

        //Target remove button

        targetRemoveButton = new Button(shell, SWT.NONE);
        targetRemoveButton.setText("Remove");
        gridData = new GridData(GridData.BEGINNING, GridData.BEGINNING,
            true, false);
        gridData.horizontalIndent = 5;
        gridData.minimumWidth = 100;
        targetRemoveButton.setLayoutData(gridData);
        targetRemoveButton.addSelectionListener(new SelectionAdapter()
        {
            public void widgetSelected(SelectionEvent arg0)
            {
                String[] selectionResult = targetEntityList.getSelection();

                //for each selected string
                for (String selected : selectionResult)
                {
                    //search among all targetAddedEntities
                    for (int j = 0 ; j < targetAddedEntities.size() ; j++)
                    {
                        physicalEntity entity = targetAddedEntities.get(j);

                        //if corresponding entity is found
                        if (selected != null &&
                            selected.equals(getKeyNAME(entity)))
                        {
View Full Code Here

Examples of org.biopax.paxtools.model.level2.physicalEntity

     
      //for each entity
      while(addedEntitiesIterator.hasNext())
      {
        //Get next entity
        physicalEntity entity = addedEntitiesIterator.next();
       
        //States of entity in Node type
        Set<Node> entityNodeStates = new HashSet<Node>();
       
        //States of entity in GraphObject type
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.