Author: rodche
Date: 2012-06-29 15:15:14 -0700 (Fri, 29 Jun 2012)
New Revision: 29730

Modified:
   
core3/impl/trunk/biopax-impl/src/main/java/org/cytoscape/biopax/internal/BioPaxMapper.java
   
core3/impl/trunk/biopax-impl/src/main/java/org/cytoscape/biopax/internal/view/BioPaxDetailsPanel.java
Log:
Sacrifice one attribute (BioPAX OWL fragment to show in the right results 
panel) for networks > 100 nodes, for performance/memoory...

Modified: 
core3/impl/trunk/biopax-impl/src/main/java/org/cytoscape/biopax/internal/BioPaxMapper.java
===================================================================
--- 
core3/impl/trunk/biopax-impl/src/main/java/org/cytoscape/biopax/internal/BioPaxMapper.java
  2012-06-29 18:47:27 UTC (rev 29729)
+++ 
core3/impl/trunk/biopax-impl/src/main/java/org/cytoscape/biopax/internal/BioPaxMapper.java
  2012-06-29 22:15:14 UTC (rev 29730)
@@ -691,9 +691,13 @@
                
                // add a piece of the BioPAX (RDF/XML without parent|child 
elements)
                
-               String owl = BioPaxUtil.toOwl(element); // (requires 
common-lang-2.4 bundle to be started)
-               AttributeUtil.set(network, node, CyNetwork.HIDDEN_ATTRS, 
BioPaxUtil.BIOPAX_DATA, owl, String.class);
                
+               //the following attr. was experimental, not so important for 
users...
+               if(network.getNodeCount() < 100) { //- this condition was added 
for performance/memory...
+                       String owl = BioPaxUtil.toOwl(element); // (requires 
common-lang-2.4 bundle to be started)
+                       AttributeUtil.set(network, node, 
CyNetwork.HIDDEN_ATTRS, BioPaxUtil.BIOPAX_DATA, owl, String.class);
+               }
+               
                String name = 
BioPaxUtil.truncateLongStr(BioPaxUtil.getNodeName(element) + "");
                
                if (!(element instanceof Interaction)) {

Modified: 
core3/impl/trunk/biopax-impl/src/main/java/org/cytoscape/biopax/internal/view/BioPaxDetailsPanel.java
===================================================================
--- 
core3/impl/trunk/biopax-impl/src/main/java/org/cytoscape/biopax/internal/view/BioPaxDetailsPanel.java
       2012-06-29 18:47:27 UTC (rev 29729)
+++ 
core3/impl/trunk/biopax-impl/src/main/java/org/cytoscape/biopax/internal/view/BioPaxDetailsPanel.java
       2012-06-29 22:15:14 UTC (rev 29730)
@@ -209,8 +209,8 @@
                
                // excerpt from the BioPAX OWL
                stringRef = null;
+               //the following attr. was experimental, not so important for 
users; may be null (not generated) in large networks
         stringRef = 
network.getRow(node,CyNetwork.HIDDEN_ATTRS).get(BioPaxUtil.BIOPAX_DATA, 
String.class);
-        //stringRef = row.get(BioPaxUtil.BIOPAX_DATA, String.class);
         if (stringRef != null) {
                appendHeader("BioPAX L3 (fragment)", buf);
             buf.append("<pre class='excerpt'>" + 
StringEscapeUtils.escapeXml(stringRef) + "</pre>");

-- 
You received this message because you are subscribed to the Google Groups 
"cytoscape-cvs" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/cytoscape-cvs?hl=en.

Reply via email to