|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface SourceFile
A SourceFile
is an immutable representations of a Java
language source file. It consists of a package name, a list of
Import
s, and a list of GlobalDecl
s.
Method Summary | |
---|---|
java.util.List |
decls()
Get the source's top-level declarations. |
SourceFile |
decls(java.util.List decls)
Set the source's top-level declarations. |
java.util.List |
imports()
Get the source's declared imports. |
SourceFile |
imports(java.util.List imports)
Set the source's declared imports. |
ImportTable |
importTable()
Get the source's import table. |
SourceFile |
importTable(ImportTable importTable)
Set the source's import table. |
PackageNode |
package_()
Get the source's declared package. |
SourceFile |
package_(PackageNode package_)
Set the source's declared package. |
Source |
source()
Get the source file. |
SourceFile |
source(Source source)
Set the source file. |
Methods inherited from interface polyglot.ast.Node |
---|
childExpectedType, del, del, dump, ext, ext, ext, ext, position, position, visit, visitChild, visitEdge, visitList |
Methods inherited from interface polyglot.ast.JL |
---|
init, node |
Methods inherited from interface polyglot.ast.NodeOps |
---|
addDecls, addMembers, addMembersEnter, buildTypes, buildTypesEnter, disambiguate, disambiguateEnter, enterScope, enterScope, exceptionCheck, exceptionCheckEnter, prettyPrint, throwTypes, translate, typeCheck, typeCheckEnter, visitChildren |
Methods inherited from interface polyglot.util.Copy |
---|
copy |
Method Detail |
---|
PackageNode package_()
SourceFile package_(PackageNode package_)
java.util.List imports()
Import
.SourceFile imports(java.util.List imports)
imports
- A list of Import
.java.util.List decls()
TopLevelDecl
.SourceFile decls(java.util.List decls)
decls
- A list of TopLevelDecl
.ImportTable importTable()
SourceFile importTable(ImportTable importTable)
Source source()
SourceFile source(Source source)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |