Exemplo n.º 1
0
 public static int getNetworkConnectionCount(GXLGraph cArch) {
   int count = 0;
   for (int y = 0; y < cArch.getGraphElementCount(); ++y) {
     if (cArch.getGraphElementAt(y) instanceof GXLEdge) ++count;
   }
   return count;
 }
Exemplo n.º 2
0
 // This this needs this loop, because the network edges are attached
 // to the cArch rather than the mArch
 public static int getMachinesCount(GXLGraph cArch) {
   int count = 0;
   for (int y = 0; y < cArch.getGraphElementCount(); ++y) {
     if (cArch.getGraphElementAt(y) instanceof GXLNode) ++count;
   }
   return count;
 }
Exemplo n.º 3
0
 public static GXLEdge getLogicalProcessorConnectionAt(GXLGraph e, int y) {
   int all = e.getGraphElementCount();
   int lcount = 0;
   for (int r = 0; r < all; ++r) {
     if (e.getGraphElementAt(r) instanceof GXLNode) ++lcount;
   }
   return (GXLEdge) e.getGraphElementAt(lcount + y);
 }
Exemplo n.º 4
0
 public static int getLogicalProcessorCount(GXLGraph e) {
   int all = e.getGraphElementCount();
   int lcount = 0;
   for (int r = 0; r < all; ++r) {
     if (e.getGraphElementAt(r) instanceof GXLNode) ++lcount;
   }
   return lcount;
 }
Exemplo n.º 5
0
 public static int getClusterCount(GXLGraph graph) {
   return graph.getGraphElementCount();
 }
Exemplo n.º 6
0
 public static GXLNode getLogicalProcessorAt(GXLGraph e, int y) {
   return (GXLNode) e.getGraphElementAt(y);
 }
Exemplo n.º 7
0
 public static GXLNode getMachineAt(GXLGraph graph, int i) {
   return (GXLNode) graph.getGraphElementAt(i);
 }
Exemplo n.º 8
0
 public static GXLEdge getNetworkConnectionAt(GXLGraph cArch, int i) {
   return (GXLEdge) cArch.getGraphElementAt(getMachinesCount(cArch) + i);
 }
Exemplo n.º 9
0
 public static GXLNode getClusterAt(GXLGraph graph, int i) {
   return (GXLNode) graph.getGraphElementAt(i);
 }