Package com.google.javascript.jscomp
Class PassConfig
- java.lang.Object
-
- com.google.javascript.jscomp.PassConfig
-
- Direct Known Subclasses:
DefaultPassConfig,PassConfig.PassConfigDelegate
public abstract class PassConfig extends java.lang.ObjectPass factories and meta-data for native Compiler passes.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classPassConfig.PassConfigDelegateAn implementation of PassConfig that just proxies all its method calls into an inner class.
-
Field Summary
Fields Modifier and Type Field Description protected CompilerOptionsoptions
-
Constructor Summary
Constructors Constructor Description PassConfig(CompilerOptions options)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract PassListBuildergetChecks()Gets the checking passes to run.protected abstract PassListBuildergetFinalizations()Gets the finalization passes to run.protected abstract PassListBuildergetOptimizations()Gets the optimization passes to run.protected PassListBuildergetTranspileOnlyPasses()Gets the transpilation passesprotected PassListBuildergetWhitespaceOnlyPasses()Gets additional checking passes that are run always, even in "whitespace only" mode.
-
-
-
Field Detail
-
options
protected final CompilerOptions options
-
-
Constructor Detail
-
PassConfig
public PassConfig(CompilerOptions options)
-
-
Method Detail
-
getWhitespaceOnlyPasses
protected PassListBuilder getWhitespaceOnlyPasses()
Gets additional checking passes that are run always, even in "whitespace only" mode. For very specific cases where processing is required even in a mode which is intended not to have any processing - specifically introduced to support goog.module() usage.
-
getTranspileOnlyPasses
protected PassListBuilder getTranspileOnlyPasses()
Gets the transpilation passes
-
getChecks
protected abstract PassListBuilder getChecks()
Gets the checking passes to run.Checking passes revolve around emitting warnings and errors. They also may include pre-processor passes needed to do error analysis more effectively.
Clients that only want to analyze code (like IDEs) and not emit code will only run checks and not optimizations.
-
getOptimizations
protected abstract PassListBuilder getOptimizations()
Gets the optimization passes to run.Optimization passes revolve around producing smaller and faster code. They should always run after checking passes.
-
getFinalizations
protected abstract PassListBuilder getFinalizations()
Gets the finalization passes to run.Finalization passes include the injection of locale-specific code and converting the AST to its final form for output.
-
-