コード例 #1
0
  private List<CyNetworkView> getViews(String file) throws Exception {
    final SIFNetworkReader snvp = readFile(file);
    final CyNetwork[] networks = snvp.getNetworks();
    final List<CyNetworkView> views = new ArrayList<CyNetworkView>();

    for (CyNetwork network : networks) {
      views.add(snvp.buildCyNetworkView(network));
    }

    return views;
  }
コード例 #2
0
  private SIFNetworkReader readFile(String file) throws Exception {
    File f = new File("./src/test/resources/testData/sif/" + file);
    SIFNetworkReader snvp =
        new SIFNetworkReader(
            new FileInputStream(f),
            layouts,
            viewFactory,
            netFactory,
            this.networkManager,
            this.rootNetworkManager);
    new TaskIterator(snvp);
    snvp.run(taskMonitor);

    return snvp;
  }
コード例 #3
0
 private CyNetwork[] getNetworks(String file) throws Exception {
   final SIFNetworkReader snvp = readFile(file);
   return snvp.getNetworks();
 }