public class PersistentInputStore
extends java.lang.Object
We separate the api into addInput(String, String)
for the worker
and getCachedCompilerInput(SourceFile)
for the compiler since there
may be discrepancies from how the compiler forms its inputs and what blaze lists as the inputs to
the compiler process. For example, the blaze inputs could list protos for conformance config, js
files that are symlinked to the --js location, or zip files all of which do not align 1 to 1 with
--js source inputs.
This class assumes that there may not be perfect mappings from blaze inputs to compiler inputs and tries to gracefully fallback to correct behavior if something doesn't match up.
Constructor and Description |
---|
PersistentInputStore() |
Modifier and Type | Method and Description |
---|---|
void |
addInput(java.lang.String path,
java.lang.String digest)
Used by the worker to populate the blaze inputs for which the compiler can associate
CompilerInput objects with.
|
CompilerInput |
getCachedCompilerInput(SourceFile source)
Returns the CompilerInput if it was cached from a previous run.
|
public void addInput(java.lang.String path, java.lang.String digest)
public CompilerInput getCachedCompilerInput(SourceFile source)
If a matching blaze input cannot be found, just create a new compiler input for scratch.
Copyright © 2009-2017 Google. All Rights Reserved.