|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sun.jini.tool.classdepend.ClasspathPackages
public class ClasspathPackages
Utility class for finding the names of packages in a class path.
Constructor Summary | |
---|---|
ClasspathPackages()
|
Method Summary | |
---|---|
private static void |
addPackage(JarEntry entry,
Set packages)
Adds the package of the class named by the JAR entry, if any |
private static void |
addPackages(String top,
String dir,
Set packages)
Adds packages of classes recursively located in the directory, using the top argument to specify the top level directory containing the package hierarchy. |
static Set |
compute(String classpath)
Computes the packages in the specified class path. |
static void |
main(String[] args)
Prints the packages in the class path to standard output using the default character encoding. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ClasspathPackages()
Method Detail |
---|
public static void main(String[] args)
args
- the argumentspublic static Set compute(String classpath)
File.pathSeparator
character. Empty names are
treated as the current directory, names ending in the File.separator
character are treated as directories, and
other names are treated as JAR files. Directories or JAR files that
have errors when they are accessed will be ignored.
classpath
- the class path
private static void addPackages(String top, String dir, Set packages)
private static void addPackage(JarEntry entry, Set packages)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |