com.google.javascript.jscomp
Interface CompilerOptions.AliasTransformation

Enclosing class:
CompilerOptions

public static interface CompilerOptions.AliasTransformation

A Role Specific Interface for the JsCompiler to report aliases used to change the code during a compile.

While aliases defined by goog.scope are expected to by only 1 per file, and the only top level structure in the file, this is not enforced.


Method Summary
 void addAlias(String alias, String definition)
          Adds an alias definition to the AliasTransformation instance.
 

Method Detail

addAlias

void addAlias(String alias,
              String definition)
Adds an alias definition to the AliasTransformation instance.

Last definition for a given alias is kept if an alias is inserted multiple times (since this is generally the behavior in JavaScript code).

Parameters:
alias - the name of the alias.
definition - the definition of the alias.