public static class Algorithms.PathWay extends Object implements Comparable<Algorithms.PathWay>
Modifier and Type | Field and Description |
---|---|
Map<org.cytoscape.model.CyNode,String> |
nodeIdMap
the map of node names in the nodeList
|
ArrayList<org.cytoscape.model.CyNode> |
nodeList
the list of nodes in order in the path
|
double |
weight
the total weight of the path
|
Constructor and Description |
---|
PathWay(ArrayList<org.cytoscape.model.CyNode> nodeList,
Map<org.cytoscape.model.CyNode,String> map,
double weight)
Constructor for the path class
|
Modifier and Type | Method and Description |
---|---|
int |
compareTo(Algorithms.PathWay o)
Use for sorting the path results
Sort by weight, if weight is equal then sort by the name of the nodes
if name is equal then return the path with less nodes
|
boolean |
equals(Object o) |
org.cytoscape.model.CyNode |
get(int i)
Returns the ith node in the path
|
int |
hashCode() |
int |
size()
Returns the size of the path
|
public ArrayList<org.cytoscape.model.CyNode> nodeList
public double weight
public PathWay(ArrayList<org.cytoscape.model.CyNode> nodeList, Map<org.cytoscape.model.CyNode,String> map, double weight)
nodeList
- the list of nodes in order in the pathmap
- the map of the original network, use to find names of the nodesweight
- the total weight of the pathpublic int size()
public org.cytoscape.model.CyNode get(int i)
i
- the rank of the node to getpublic int compareTo(Algorithms.PathWay o)
compareTo
in interface Comparable<Algorithms.PathWay>
Copyright © 2018. All rights reserved.