Class Uphill
java.lang.Object
|
+--Uphill
- public class Uphill
- extends java.lang.Object
Uphill.java
Jim Gast, jgast@cs.wisc.edu.
This program reads an AS_routes file containing
AS traceroutes. For each traceroute, it outputs a line
that says GOOD if the route matches the route ASTree would have
predicted or VALID if the route at least goes along a route that
never goes back uphill after it first went downhill.
Routes are BAD if they ever go uphill to a node closer to the
backbone after having gone downhill.
For the tiers of the Internet, the file uses the hopsToBackbone
calculation from MakeASTree or MakeBBASTree. See the ASTree.txt
file.
USAGE: java Uphill routingsFile
- routingsFile, optional, default "Traces.txt"
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
asList
public static ASN[] asList
MAX_HOPS
public static final int MAX_HOPS
- See Also:
- Constant Field Values
GOOD
public static final int GOOD
- See Also:
- Constant Field Values
goodLines
public static int[] goodLines
VALID
public static final int VALID
- See Also:
- Constant Field Values
validLines
public static int[] validLines
BAD
public static final int BAD
- See Also:
- Constant Field Values
badLines
public static int[] badLines
errors
public static int[] errors
altParent
public static ASN[] altParent
altCount
public static int[] altCount
usedParent
public static int[] usedParent
learningParents
public static boolean learningParents
learningDepth
public static boolean learningDepth
INFINITELY_DEEP
public static final int INFINITELY_DEEP
- See Also:
- Constant Field Values
Uphill
public Uphill()
main
public static void main(java.lang.String[] args)
throws java.io.IOException
- For each traceroute, classify it as GOOD, VALID, or BAD.
java.io.IOException
testTraces
public static void testTraces(java.lang.String routingsFile,
java.lang.String title)
throws java.io.IOException
java.io.IOException
clearCounters
public static void clearCounters(int[] counter)
hopLength
public static int hopLength(java.lang.String routeLine)
- counts the number of AS hops on this wholeASRoute line
hasGoodShape
public static int hasGoodShape(java.lang.String routeLine)
anyParentMatches
public static boolean anyParentMatches(ASN fromAS,
ASN toAS)
learnNewDepth
public static void learnNewDepth(ASN fromAS,
ASN toAS)
computeAllHopsToBackbone
public static void computeAllHopsToBackbone()
printReversals
public static void printReversals()
printAdditions
public static void printAdditions()
printStats
public static void printStats(java.lang.String title)