Code example for Random

0
/** 
 * Utility methods used in various Job Control unit tests. 
 */ 
public class JobControlTestUtils { 
 
  static private Random rand = new Random();
 
  private static NumberFormat idFormat = NumberFormat.getInstance();
 
  static { 
    idFormat.setMinimumIntegerDigits(4);
    idFormat.setGroupingUsed(false);
  } 
 
  /** 
   * Cleans the data from the passed Path in the passed FileSystem. 
   *  
   * @param fs FileSystem to delete data from. 
   * @param dirPath Path to be deleted. 
   * @throws IOException If an error occurs cleaning the data.