public class ClassFileUtilities
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
protected static class |
ClassFileUtilities.ClassFile |
protected static class |
ClassFileUtilities.Jar |
protected static class |
ClassFileUtilities.Triple |
Modifier and Type | Field and Description |
---|---|
static byte |
CONSTANT_CLASS_INFO |
static byte |
CONSTANT_DOUBLE_INFO |
static byte |
CONSTANT_FIELDREF_INFO |
static byte |
CONSTANT_FLOAT_INFO |
static byte |
CONSTANT_INTEGER_INFO |
static byte |
CONSTANT_INTERFACEMETHODREF_INFO |
static byte |
CONSTANT_LONG_INFO |
static byte |
CONSTANT_METHODREF_INFO |
static byte |
CONSTANT_NAMEANDTYPE_INFO |
static byte |
CONSTANT_STRING_INFO |
static byte |
CONSTANT_UTF8_INFO |
Modifier | Constructor and Description |
---|---|
protected |
ClassFileUtilities()
This class does not need to be instantiated.
|
Modifier and Type | Method and Description |
---|---|
static java.util.Set |
getClassDependencies(java.io.InputStream is)
Returns the dependencies of the given class.
|
static java.util.Set |
getClassDependencies(java.io.InputStream is,
java.util.Set classpath,
boolean rec) |
static java.util.Set |
getClassDependencies(java.lang.String path,
java.util.Set classpath,
boolean rec)
Returns the dependencies of the given class.
|
protected static java.util.Set |
getDescriptorClasses(java.lang.String desc)
Returns the classes contained in a field or method desciptor.
|
static void |
main(java.lang.String[] args)
Program that computes the dependencies between the Batik jars.
|
public static final byte CONSTANT_UTF8_INFO
public static final byte CONSTANT_INTEGER_INFO
public static final byte CONSTANT_FLOAT_INFO
public static final byte CONSTANT_LONG_INFO
public static final byte CONSTANT_DOUBLE_INFO
public static final byte CONSTANT_CLASS_INFO
public static final byte CONSTANT_STRING_INFO
public static final byte CONSTANT_FIELDREF_INFO
public static final byte CONSTANT_METHODREF_INFO
public static final byte CONSTANT_INTERFACEMETHODREF_INFO
public static final byte CONSTANT_NAMEANDTYPE_INFO
protected ClassFileUtilities()
public static void main(java.lang.String[] args)
Run this from the main Batik distribution directory, after building the jars. For every jar file in the batik-xxx/ build directory, it will determine which other jar files it directly depends on. The output is lines of the form:
number,from,to
where mean that the from jar has number class files that depend on class files in the to jar.
public static java.util.Set getClassDependencies(java.lang.String path, java.util.Set classpath, boolean rec) throws java.io.IOException
path
- The root class path.classpath
- The set of directories (Strings) to scan.rec
- Whether to follow dependencies recursively.java.io.IOException
public static java.util.Set getClassDependencies(java.io.InputStream is, java.util.Set classpath, boolean rec) throws java.io.IOException
java.io.IOException
public static java.util.Set getClassDependencies(java.io.InputStream is) throws java.io.IOException
java.io.IOException
protected static java.util.Set getDescriptorClasses(java.lang.String desc)
Copyright © 2022 Apache Software Foundation. All Rights Reserved.