org.extendj.ast
class PathPart

General Info

Type Hierarchy:
java.lang.Object
  extended by org.extendj.ast.PathPart
Direct Known Subclasses:
FolderPath, JarFilePath, SourceFilePath

Description

Source
Declared in /home/jesper/git/extendj/java4/frontend/PathPart.jadd at line 304
Aspect
PathPart

Member Filters

API level:

Aspect:

Constructors

protected PathPart(boolean isSource)

Methods

public abstract java.lang.String getPath()
Returns:
the path which this path part represents
public abstract boolean hasPackage(java.lang.String name)
Test if a package is available in this path part.

The implementations of this method may use caching to improve the efficiency of subsequent calls to the method.

Returns:
true if the given package name exists in this path part
public static PathPart createSourcePath(java.lang.String fileName)
public static PathPart createClassPath(java.lang.String fileName)
public ClassSource findSource(java.lang.String name)
Retrieves a compilation unit based on the canonical name.
Parameters:
name - the canonical name of the class to lookup
Returns:
null if a compilation unit with the given name is not available in this PathPart.
public CompilationUnit getCompilationUnit(Program program,
                                          java.lang.String name)
                                   throws java.io.IOException
Load the compilation unit of a class.
Parameters:
program -
name - The canonical name of the class.
Throws:
java.io.IOException

Fields

protected final boolean isSource
This is true if this path part represents a source path, true if this path part represents a bytecode class path.
protected final java.lang.String fileSuffix
The file suffix of source files in this path part.

Inherited Members

Methods inherited from class java.lang.Object

clone
equals
finalize
getClass
hashCode
notify
notifyAll
toString
wait
wait
wait