@@ -0,0 +1,1286 @@
+package org.team2168.utils;%0A%0Aimport java.util.Vector;%0A%0A/**%0A* Contains basic functions that are used often.%0A*%0A* Initial revision from 254's 2013 robot code:%0A*   https://github.com/Team254/FRC-2013/blob/master/src/com/team254/lib/util/Util.java%0A*%0A* @author richard@team254.com (Richard Lin)%0A* @author brandon.gonzalez.451@gmail.com (Brandon Gonzalez)%0A*/%0Apublic class Util %7B%0A  // Prevent this class from being instantiated.%0A  private Util() %7B%0A  %7D%0A%0A  /**%0A* Limits the given input to the given magnitude.%0A*/%0A  public static double limit(double v, double limit) %7B%0A    return (Math.abs(v) %3C limit) ? v : limit * (v %3C 0 ? -1 : 1);%0A  %7D%0A%0A  /**%0A* Returns the array of substrings obtained by dividing the given input string at each occurrence%0A* of the given delimiter.%0A*/%0A  public static String%5B%5D split(String input, String delimiter) %7B%0A    Vector node = new Vector();%0A    int index = input.indexOf(delimiter);%0A    while (index %3E= 0) %7B%0A      node.addElement(input.substring(0, index));%0A      input = input.substring(index + delimiter.length());%0A      index = input.indexOf(delimiter);%0A    %7D%0A    node.addElement(input);%0A%0A    String%5B%5D retString = new String%5Bnode.size()%5D;%0A    for (int i = 0; i %3C node.size(); ++i) %7B%0A      retString%5Bi%5D = (String) node.elementAt(i);%0A    %7D%0A%0A    return retString;%0A  %7D%0A%7D%0A

Create Util.java