Package com.google.javascript.jscomp
Class FieldCleanupPass
java.lang.Object
com.google.javascript.jscomp.FieldCleanupPass
- All Implemented Interfaces:
CompilerPass
,HotSwapCompilerPass
A CleanupPass implementation that will remove all field declarations on
JSTypes contributed by the original file.
This pass is expected to clear out declarations contributed to any JSType, even if the constructor declaration is not provided in the file being updated.
-
Constructor Summary
-
Method Summary
-
Constructor Details
-
FieldCleanupPass
-
-
Method Details
-
hotSwapScript
Description copied from interface:HotSwapCompilerPass
Process the JS with root node root. This is supposed to be significantly faster compared to corresponding full-compiler passes.- Specified by:
hotSwapScript
in interfaceHotSwapCompilerPass
- Parameters:
scriptRoot
- Root node corresponding to the file that is modified, should be of typeToken.SCRIPT
.originalRoot
- Root node corresponding to the original version of the file that is modified. Should be of typetoken.SCRIPT
.
-
process
Description copied from interface:CompilerPass
Process the JS with root node root. Can modify the contents of each Node tree- Specified by:
process
in interfaceCompilerPass
- Parameters:
externs
- Top of external JS treeroot
- Top of JS tree
-