Author: slotia
Date: 2012-08-27 14:32:38 -0700 (Mon, 27 Aug 2012)
New Revision: 30279
Modified:
core3/api/trunk/viewmodel-api/src/main/java/org/cytoscape/view/model/CyNetworkView.java
Log:
Documented flushPayloadEvents
Modified:
core3/api/trunk/viewmodel-api/src/main/java/org/cytoscape/view/model/CyNetworkView.java
===================================================================
---
core3/api/trunk/viewmodel-api/src/main/java/org/cytoscape/view/model/CyNetworkView.java
2012-08-27 20:54:41 UTC (rev 30278)
+++
core3/api/trunk/viewmodel-api/src/main/java/org/cytoscape/view/model/CyNetworkView.java
2012-08-27 21:32:38 UTC (rev 30279)
@@ -47,16 +47,29 @@
* Additional methods for CyNetworkView. Network view should implement BOTH
View
* and CyNetworkView.
*
- * Consolidated data structure for graph object views.
+ * <p>
+ * <i>Warning</i>: if you just added a node or edge in
+ * {@link org.cytoscape.model.CyNetwork},
+ * {@link #getNodeView} or {@link #getEdgeView}
+ * will probably return null for the newly created node or edge.
+ * You may have to call
+ * {@link org.cytoscape.event.CyEventHelper#flushPayloadEvents}
+ * <i>prior</i> to calling {@link #getNodeView} or {@link #getEdgeView},
+ * so that the {@code CyNetworkView} gets a chance to create the views.
+ * If you are creating a bunch of nodes and edges at once, call {@code
flushPayloadEvents}
+ * <i>after</i> all the nodes and edges are created.
+ * </p>
+ *
* @CyAPI.Api.Interface
*/
public interface CyNetworkView extends View<CyNetwork>, CyDisposable {
/**
* Returns a View for a specified Node.
+ *
*
* @param node Node object
- *
+ *
* @return View for the given node object.
*/
View<CyNode> getNodeView(final CyNode node);
--
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.