Package org.cytoscape.model
Interface CyNetworkFactory
public interface CyNetworkFactory
A singleton factory object used for instantiating CyNetwork
objects. The CyNetworkFactory should be available as an
OSGi service.
Module: model-api
To use this in your app, include the following dependency in your POM:
<dependency>
<groupId>org.cytoscape</groupId>
<artifactId>model-api</artifactId>
</dependency>Cytoscape Backwards Compatibility (API Interface): We expect that this interface will be used but not implemented by developers using this interface. As such, we reserve the right to add methods to the interface as part of minor version upgrades. We will not remove methods for any changes other than major version upgrades.
-
Method Summary
Modifier and TypeMethodDescriptionReturns a new, emptyCyNetworkobject.createNetwork(SavePolicy policy) Returns a new, emptyCyNetworkobject.Returns a new, emptyCyNetworkobject where the associated default tables are private.Returns a new, emptyCyNetworkobject where the associated default tables are private.
-
Method Details
-
createNetwork
CyNetwork createNetwork()Returns a new, emptyCyNetworkobject. The new network's save policy isSavePolicy.SESSION_FILEby default. If you want to create a network that should not be saved in session files, use thecreateNetwork(SavePolicy)method instead, and set the save policy toSavePolicy.DO_NOT_SAVE.- Returns:
- A new, empty
CyNetworkobject.
-
createNetwork
Returns a new, emptyCyNetworkobject.- Parameters:
policy- the save policy to follow during the life-cycle of the CyNetwork.- Returns:
- A new, empty
CyNetworkobject.
-
createNetworkWithPrivateTables
CyNetwork createNetworkWithPrivateTables()Returns a new, emptyCyNetworkobject where the associated default tables are private. This method should only be used in special cases where the network created is not intended to be used or shared like a normal network within the system. The new network's save policy isSavePolicy.SESSION_FILEby default. If you want to create a network that should not be saved in session files, use thecreateNetwork(SavePolicy)method instead, and set the save policy toSavePolicy.DO_NOT_SAVE.- Returns:
- A new, empty
CyNetworkobject.
-
createNetworkWithPrivateTables
Returns a new, emptyCyNetworkobject where the associated default tables are private. This method should only be used in special cases where the network created is not intended to be used or shared like a normal network within the system.- Parameters:
policy- the save policy to follow during the life-cycle of the CyNetwork.- Returns:
- A new, empty
CyNetworkobject.
-