@Test(groups="UNIX") public void testGetRunningPids() throws Exception { int ownpid = MonitorUtils.findOwnPid(); List<Integer> javapids = MonitorUtils.getRunningPids("java"); assertTrue(javapids.contains(ownpid), "javapids="+javapids+"; ownpid="+ownpid); }
public static List<Integer> getRunningPids(String regex) { return getRunningPids(regex, null); }
MonitorUtils { public static List<Integer> getRunningPids(String regex) { return getRunningPids(regex, null); } }
MonitorUtils { public static List<Integer> getRunningPids(String regex) { return getRunningPids(regex, null); }  }
MonitorUtils { public static List<Integer> getRunningPids(String regex) { return getRunningPids(regex, null); }  static boolean isUrlUp(URL url); static boolean isPidRunning(int pid); static boolean isPidRunning(int pid, String regex); static List<Integer> getRunningPids(String regex); static List<Integer> getRunningPids(String regex, String excludingRegex); static MemoryUsage getMemoryUsage(int pid); static MemoryUsage getMemoryUsage(int pid, String clazzRegexOfInterest, int minInstancesOfInterest); static List<String> searchLog(File file, String grepOfInterest); static List<String> searchLog(File file, String grepOfInterest, Set<String> grepExclusions); static Process exec(String cmd); static String waitFor(Process process); static int findOwnPid(); }
MonitorUtils { public static List<Integer> getRunningPids(String regex) { return getRunningPids(regex, null); }  static boolean isUrlUp(URL url); static boolean isPidRunning(int pid); static boolean isPidRunning(int pid, String regex); static List<Integer> getRunningPids(String regex); static List<Integer> getRunningPids(String regex, String excludingRegex); static MemoryUsage getMemoryUsage(int pid); static MemoryUsage getMemoryUsage(int pid, String clazzRegexOfInterest, int minInstancesOfInterest); static List<String> searchLog(File file, String grepOfInterest); static List<String> searchLog(File file, String grepOfInterest, Set<String> grepExclusions); static Process exec(String cmd); static String waitFor(Process process); static int findOwnPid();  }