
public class NullRebuildCache extends MinimalRebuildCache
immediateTypeRelations| Constructor and Description |
|---|
NullRebuildCache() |
| Modifier and Type | Method and Description |
|---|---|
void |
addGeneratedArtifacts(ArtifactSet generatedArtifacts)
Accumulates generated artifacts so that they can be output on recompiles even if no generators
are run.
|
void |
addModifiedCompilationUnitNames(TreeLogger logger,
Set<String> modifiedCompilationUnitNames) |
void |
addSourceCompilationUnitName(String sourceCompilationUnitName) |
void |
addTypeReference(String fromTypeName,
String toTypeName) |
void |
associateReboundTypeWithGeneratedCompilationUnitName(String reboundTypeName,
String generatedTypeName) |
void |
associateReboundTypeWithInputResource(String reboundTypeName,
String inputResourcePath)
Record that a Generator that was ran as a result of a GWT.create(ReboundType.class) call read a
particular resource.
|
void |
clearPerTypeJsCache() |
void |
clearRebinderTypeAssociations(String rebinderTypeName) |
void |
clearReboundTypeAssociations(String reboundTypeName) |
Set<String> |
computeAndClearStaleTypesCache(TreeLogger logger,
JTypeOracle typeOracle)
Calculates the set of stale types and clears their cached Js, StatementRanges and SourceMaps.
|
Set<String> |
computeDeletedTypeNames()
Computes and returns the set of names of deleted types.
|
Set<String> |
computeModifiedTypeNames()
Computes and returns the set of names of modified types.
|
Set<String> |
computeReachableTypeNames()
Computes and returns the names of the set of types that are referenceable within the method
level control flow starting from the entry methods, immortal codegen types and exported
JsInterop methods.
|
ArtifactSet |
getGeneratedArtifacts() |
String |
getJs(String typeName) |
Set<String> |
getModifiedCompilationUnitNames() |
JsIncrementalNamer.JsIncrementalNamerState |
getPersistentPrettyNamerState() |
Set<String> |
getPreambleTypeNames() |
JsSourceMap |
getSourceMap(String typeName) |
Set<String> |
getStaleTypeNames() |
StatementRanges |
getStatementRanges(String typeName) |
ResolveRuntimeTypeReferences.IntTypeMapper |
getTypeMapper() |
boolean |
hasJs(String typeName) |
boolean |
hasPreambleTypeNames() |
boolean |
isSourceCompilationUnit(String compilationUnitName) |
void |
recordBuildResources(ModuleDef module)
Records the resource paths and modification dates of build resources in the current compile and
builds a list of known modified resource paths by comparing the resource paths and modification
dates of build resources in the previous compile with those of the current compile.
|
void |
recordDiskSourceResources(Map<String,Long> currentModifiedByDiskSourcePath)
Records the paths and modification dates of source resources in the current compile and builds
a list of known modified paths by comparing the paths and modification dates of source
resources in the previous compile with those of the current compile.
|
void |
recordDiskSourceResources(ModuleDef module)
Records the paths and modification dates of source resources in the current compile and builds
a list of known modified paths by comparing the paths and modification dates of source
resources in the previous compile with those of the current compile.
|
void |
recordGeneratedUnits(Collection<GeneratedUnit> generatedUnits)
Records the paths and content ids of generated source resources in the current compile and
updates a list of known modified paths by comparing the paths and content ids of generated
source resources in the previous compile with those of the current compile.
|
void |
recordNestedTypeName(String compilationUnitTypeName,
String nestedTypeName) |
void |
recordNestedTypeNamesPerType(CompilationUnit compilationUnit) |
void |
recordRebinderTypeForReboundType(String reboundTypeName,
String rebinderType)
Records that rebinder type Foo contains a GWT.create(ReboundTypeBar.class) call.
|
void |
removeReferencesFrom(String fromTypeName) |
void |
setJsForType(TreeLogger logger,
String typeName,
String typeJs) |
void |
setJsoTypeNames(Set<String> jsoTypeNames,
Set<String> singleJsoImplInterfaceNames,
Set<String> dualJsoImplInterfaceNames)
Records the names of JSO subtypes, single impl interfaces and dual impl interfaces as well as
keeps track of types that entered or left one of the lists in the most recent iteration.
|
void |
setPreambleTypeNames(TreeLogger logger,
Set<String> preambleTypeNames) |
void |
setRootTypeNames(Collection<String> rootTypeNames) |
void |
setSourceMapForType(String typeName,
JsSourceMap sourceMap) |
void |
setStatementRangesForType(String typeName,
StatementRanges statementRanges) |
addExportedGlobalName, copyFrom, filterUnreachableTypeNames, getImmediateTypeRelations, getLastLinkedJsBytes, getProcessedStaleTypeNames, getTypeEnvironment, isPopulated, knowsLastLinkedJsBytes, markSourceFileStale, removeExportedNames, setEntryMethodNames, setLastLinkedJsBytes, setProcessedStaleTypeNamespublic void addGeneratedArtifacts(ArtifactSet generatedArtifacts)
MinimalRebuildCacheaddGeneratedArtifacts in class MinimalRebuildCachepublic void addModifiedCompilationUnitNames(TreeLogger logger, Set<String> modifiedCompilationUnitNames)
addModifiedCompilationUnitNames in class MinimalRebuildCachepublic void addSourceCompilationUnitName(String sourceCompilationUnitName)
addSourceCompilationUnitName in class MinimalRebuildCachepublic void addTypeReference(String fromTypeName, String toTypeName)
addTypeReference in class MinimalRebuildCachepublic void associateReboundTypeWithGeneratedCompilationUnitName(String reboundTypeName, String generatedTypeName)
associateReboundTypeWithGeneratedCompilationUnitName in class MinimalRebuildCachepublic void associateReboundTypeWithInputResource(String reboundTypeName, String inputResourcePath)
MinimalRebuildCacheassociateReboundTypeWithInputResource in class MinimalRebuildCachepublic void clearPerTypeJsCache()
clearPerTypeJsCache in class MinimalRebuildCachepublic void clearRebinderTypeAssociations(String rebinderTypeName)
clearRebinderTypeAssociations in class MinimalRebuildCachepublic void clearReboundTypeAssociations(String reboundTypeName)
clearReboundTypeAssociations in class MinimalRebuildCachepublic Set<String> computeAndClearStaleTypesCache(TreeLogger logger, JTypeOracle typeOracle)
MinimalRebuildCacheThe calculation of stale types starts with the list of known modified types and expands that set using various patterns intended to find any types whose output JS would be affected by the changes in the modified types. For example if the parent of class Foo was changed then the castmaps in all children of Foo need to be recreated.
In some ways this process is similar to that performed by the CompilationUnitInvalidator but it differs both in what type of cached objects are being cleared (JS versus CompilationUnits) and in what invalidation rules must be applied. CompilationUnitInvalidator is concerned only with changes in interface while the invalidation here must also look at JSO promotion/demotion and cast references because of the peculiarities of output JS format.
computeAndClearStaleTypesCache in class MinimalRebuildCachepublic Set<String> computeDeletedTypeNames()
MinimalRebuildCacheDeleted types are all those types that are nested within compilation units that are known to have been deleted.
computeDeletedTypeNames in class MinimalRebuildCachepublic Set<String> computeModifiedTypeNames()
MinimalRebuildCacheModified types are all those types that are nested within compilation units that are known to have been modified.
computeModifiedTypeNames in class MinimalRebuildCachepublic Set<String> computeReachableTypeNames()
MinimalRebuildCacheShould only be called once per compile, so that the "lastReachableTypeNames" list accurately reflects the reachable types of the immediately previous compile.
computeReachableTypeNames in class MinimalRebuildCachepublic ArtifactSet getGeneratedArtifacts()
getGeneratedArtifacts in class MinimalRebuildCachepublic ResolveRuntimeTypeReferences.IntTypeMapper getTypeMapper()
getTypeMapper in class MinimalRebuildCachepublic String getJs(String typeName)
getJs in class MinimalRebuildCachepublic Set<String> getModifiedCompilationUnitNames()
getModifiedCompilationUnitNames in class MinimalRebuildCachepublic JsIncrementalNamer.JsIncrementalNamerState getPersistentPrettyNamerState()
getPersistentPrettyNamerState in class MinimalRebuildCachepublic Set<String> getPreambleTypeNames()
getPreambleTypeNames in class MinimalRebuildCachepublic JsSourceMap getSourceMap(String typeName)
getSourceMap in class MinimalRebuildCachepublic Set<String> getStaleTypeNames()
getStaleTypeNames in class MinimalRebuildCachepublic StatementRanges getStatementRanges(String typeName)
getStatementRanges in class MinimalRebuildCachepublic boolean hasJs(String typeName)
hasJs in class MinimalRebuildCachepublic boolean hasPreambleTypeNames()
hasPreambleTypeNames in class MinimalRebuildCachepublic boolean isSourceCompilationUnit(String compilationUnitName)
isSourceCompilationUnit in class MinimalRebuildCachepublic void recordBuildResources(ModuleDef module)
MinimalRebuildCacherecordBuildResources in class MinimalRebuildCachepublic void recordDiskSourceResources(Map<String,Long> currentModifiedByDiskSourcePath)
MinimalRebuildCacherecordDiskSourceResources in class MinimalRebuildCachepublic void recordDiskSourceResources(ModuleDef module)
MinimalRebuildCacherecordDiskSourceResources in class MinimalRebuildCachepublic void recordGeneratedUnits(Collection<GeneratedUnit> generatedUnits)
MinimalRebuildCacherecordGeneratedUnits in class MinimalRebuildCachepublic void recordNestedTypeName(String compilationUnitTypeName, String nestedTypeName)
recordNestedTypeName in class MinimalRebuildCachepublic void recordNestedTypeNamesPerType(CompilationUnit compilationUnit)
recordNestedTypeNamesPerType in class MinimalRebuildCachepublic void recordRebinderTypeForReboundType(String reboundTypeName, String rebinderType)
MinimalRebuildCacherecordRebinderTypeForReboundType in class MinimalRebuildCachepublic void removeReferencesFrom(String fromTypeName)
removeReferencesFrom in class MinimalRebuildCachepublic void setJsForType(TreeLogger logger, String typeName, String typeJs)
setJsForType in class MinimalRebuildCachepublic void setJsoTypeNames(Set<String> jsoTypeNames, Set<String> singleJsoImplInterfaceNames, Set<String> dualJsoImplInterfaceNames)
MinimalRebuildCachesetJsoTypeNames in class MinimalRebuildCachepublic void setPreambleTypeNames(TreeLogger logger, Set<String> preambleTypeNames)
setPreambleTypeNames in class MinimalRebuildCachepublic void setRootTypeNames(Collection<String> rootTypeNames)
setRootTypeNames in class MinimalRebuildCachepublic void setSourceMapForType(String typeName, JsSourceMap sourceMap)
setSourceMapForType in class MinimalRebuildCachepublic void setStatementRangesForType(String typeName, StatementRanges statementRanges)
setStatementRangesForType in class MinimalRebuildCacheCopyright © 2018. All rights reserved.