Klasse ClassPath

java.lang.Object
org.aspectj.apache.bcel.util.ClassPath
Alle implementierten Schnittstellen:
Serializable

public class ClassPath extends Object implements Serializable
Responsible for loading (class) files from the CLASSPATH. Inspired by sun.tools.ClassPath.
Autor:
M. Dahm, Mario Ivankovits, Andy Clement
Siehe auch:
  • Konstruktordetails

    • ClassPath

      public ClassPath(String class_path)
      Search for classes in given path.
    • ClassPath

      @Deprecated public ClassPath()
      Veraltet.
      Use SYSTEM_CLASS_PATH constant
      Search for classes in CLASSPATH.
  • Methodendetails

    • getSystemClassPath

      public static ClassPath getSystemClassPath()
    • toString

      public String toString()
      Setzt außer Kraft:
      toString in Klasse Object
      Gibt zurück:
      used class path string
    • hashCode

      public int hashCode()
      Setzt außer Kraft:
      hashCode in Klasse Object
    • equals

      public boolean equals(Object o)
      Setzt außer Kraft:
      equals in Klasse Object
    • getClassPath

      public static final String getClassPath()
      Checks for class path components in the following properties: "java.class.path", "sun.boot.class.path", "java.ext.dirs"
      Gibt zurück:
      class path as used by default by BCEL
    • getInputStream

      public InputStream getInputStream(String name) throws IOException
      Parameter:
      name - fully qualified class name, e.g. java.lang.String
      Gibt zurück:
      input stream for class
      Löst aus:
      IOException
    • getInputStream

      public InputStream getInputStream(String name, String suffix) throws IOException
      Return stream for class or resource on CLASSPATH.
      Parameter:
      name - fully qualified file name, e.g. java/lang/String
      suffix - file name ends with suff, e.g. .java
      Gibt zurück:
      input stream for file on class path
      Löst aus:
      IOException
    • getClassFile

      public ClassPath.ClassFile getClassFile(String name, String suffix) throws IOException
      Parameter:
      name - fully qualified file name, e.g. java/lang/String
      suffix - file name ends with suff, e.g. .java
      Gibt zurück:
      class file for the java class
      Löst aus:
      IOException
    • getClassFile

      public ClassPath.ClassFile getClassFile(String name) throws IOException
      Parameter:
      name - fully qualified class name, e.g. java.lang.String
      Gibt zurück:
      input stream for class
      Löst aus:
      IOException
    • getBytes

      public byte[] getBytes(String name, String suffix) throws IOException
      Parameter:
      name - fully qualified file name, e.g. java/lang/String
      suffix - file name ends with suffix, e.g. .java
      Gibt zurück:
      byte array for file on class path
      Löst aus:
      IOException
    • getBytes

      public byte[] getBytes(String name) throws IOException
      Gibt zurück:
      byte array for class
      Löst aus:
      IOException
    • getPath

      public String getPath(String name) throws IOException
      Parameter:
      name - name of file to search for, e.g. java/lang/String.java
      Gibt zurück:
      full (canonical) path for file
      Löst aus:
      IOException
    • getPath

      public String getPath(String name, String suffix) throws IOException
      Parameter:
      name - name of file to search for, e.g. java/lang/String
      suffix - file name suffix, e.g. .java
      Gibt zurück:
      full (canonical) path for file, if it exists
      Löst aus:
      IOException