public static List<Class<?>> processJarfile(String jarPath) {
		List<Class<?>> classes = new ArrayList<Class<?>>();

		
		JarFile jarFile;

		try {
			jarFile = new JarFile(jarPath);

			// get contents of jar file and iterate through them
			Enumeration<JarEntry> entries = jarFile.entries();
			while (entries.hasMoreElements()) {
				JarEntry entry = entries.nextElement();

				// Get content name from jar file
				String entryName = entry.getName();
				String className = null;

				// If content is a class save class name.
				if (entryName.endsWith(".class")) {
					className = entryName.replace('/', '.').replace('\\', '.').replace(".class", "");
				}

				log("JarEntry '" + entryName + "'  =>  class '" + className + "'");

				// If content is a class add class to List
				if (className != null) {
					classes.add(loadClass(className));
					continue;
				}

				// If jar contains another jar then iterate through it
				if (entryName.endsWith(".jar")) {
					classes.addAll(processJarfile(entryName));
					continue;
				}
				// If content is a directory
				File subdir = new File(entryName);
				if (subdir.isDirectory()) {
					classes.addAll(processDirectory(subdir));
				}

			}
			jarFile.close();
		} catch (IOException e) {
			throw new RuntimeException("Unexpected IOException reading JAR File '" + jarPath + "'", e);
		}

		return classes;
	}