org.apache.hadoop.hbase.mapreduce.hadoopbackport
Class JarFinder
java.lang.Object
org.apache.hadoop.hbase.mapreduce.hadoopbackport.JarFinder
public class JarFinder
- extends Object
Finds the Jar for a class. If the class is in a directory in the
classpath, it creates a Jar on the fly with the contents of the directory
and returns the path to that Jar. If a Jar is created, it is created in
the system temporary directory.
This file was forked from hadoop/common/branches/branch-2@1377176.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
JarFinder
public JarFinder()
jarDir
public static void jarDir(File dir,
String relativePath,
ZipOutputStream zos)
throws IOException
- Throws:
IOException
getJar
public static String getJar(Class klass)
- Returns the full path to the Jar containing the class. It always return a
JAR.
- Parameters:
klass
- class.
- Returns:
- path to the Jar containing the class.
Copyright © 2007–2015 The Apache Software Foundation. All rights reserved.