public class JavacState extends Object
This is NOT part of any supported API. If you write code that depends on this, you do so at your own risk. This code and its internal interfaces are subject to change or deletion without notice.
Modifier and Type | Method and Description |
---|---|
void |
checkSourceStatus(boolean check_gensrc)
Go through all sources and check which have been removed, added or modified
and taint the corresponding packages.
|
void |
clearTaintedPackages()
Clean out the tainted package set, used after the first round of compiles,
prior to propagating dependencies.
|
void |
compareWithMakefileList(File makefileSourceList)
Compare the calculate source list, with an explicit list, usually supplied from the makefile.
|
void |
deleteClassArtifactsInTaintedPackages()
Delete all prev artifacts in the currently tainted packages.
|
void |
findAllArtifacts()
Find all artifacts that exists on disk.
|
Transformer |
getCopier()
Acquire the copying transform.
|
Map<String,Transformer> |
getJavaSuffixRule()
Acquire the compile_java_packages suffix rule for .java files.
|
boolean |
isIncremental()
Returns true if this is an incremental build.
|
static JavacState |
load(String[] args,
File binDir,
File gensrcDir,
File headerDir,
boolean permitUnidentifiedArtifacts,
PrintStream out,
PrintStream err)
Load a javac_state file.
|
BuildState |
now() |
void |
performCopying(File binDir,
Map<String,Transformer> suffixRules)
Run the copy translator only.
|
boolean |
performJavaCompilations(File binDir,
String serverSettings,
String[] args,
Set<String> recentlyCompiled,
boolean[] rcValue)
Compile all the java sources.
|
void |
performTranslation(File gensrcDir,
Map<String,Transformer> suffixRules)
Run all the translators that translate into java source code.
|
BuildState |
prev() |
void |
removeSuperfluousArtifacts(Set<String> recentlyCompiled)
Remove artifacts that are no longer produced when compiling!
|
void |
removeUnidentifiedArtifacts()
Scan all output dirs for artifacts and remove those files (artifacts?)
that are not recognized as such, in the javac_state file.
|
void |
save()
Save the javac_state file.
|
void |
setVisibleClasses(Map<String,Source> vs)
Specify which classes are visible to the compiler through -classpath.
|
void |
setVisibleSources(Map<String,Source> vs)
Specify which sources are visible to the compiler through -sourcepath.
|
Set<String> |
taintedPackages()
This packages need recompilation.
|
void |
taintPackage(String name,
String because)
Mark a java package as tainted, ie it needs recompilation.
|
void |
taintPackagesDependingOnChangedPackages(Set<String> pkgs,
Set<String> recentlyCompiled)
Propagate recompilation through the dependency chains.
|
void |
taintPackagesThatMissArtifacts()
If artifacts have gone missing, force a recompile of the packages
they belong to.
|
public BuildState prev()
public BuildState now()
public void setVisibleSources(Map<String,Source> vs)
public void setVisibleClasses(Map<String,Source> vs)
public boolean isIncremental()
public void findAllArtifacts()
public void deleteClassArtifactsInTaintedPackages()
public void save() throws IOException
IOException
public static JavacState load(String[] args, File binDir, File gensrcDir, File headerDir, boolean permitUnidentifiedArtifacts, PrintStream out, PrintStream err)
public void taintPackage(String name, String because)
public void clearTaintedPackages()
public void checkSourceStatus(boolean check_gensrc)
public Map<String,Transformer> getJavaSuffixRule()
public Transformer getCopier()
public void taintPackagesThatMissArtifacts()
public void taintPackagesDependingOnChangedPackages(Set<String> pkgs, Set<String> recentlyCompiled)
public void removeUnidentifiedArtifacts()
public void removeSuperfluousArtifacts(Set<String> recentlyCompiled)
public void performCopying(File binDir, Map<String,Transformer> suffixRules)
public void performTranslation(File gensrcDir, Map<String,Transformer> suffixRules)
public boolean performJavaCompilations(File binDir, String serverSettings, String[] args, Set<String> recentlyCompiled, boolean[] rcValue)
public void compareWithMakefileList(File makefileSourceList) throws ProblemException
ProblemException
Copyright © 2017 earcam. All rights reserved.