Class JsFunctionParser
java.lang.Object
com.google.javascript.jscomp.deps.JsFileLineParser
com.google.javascript.jscomp.deps.JsFunctionParser
A parser that can extract dependency information from a .js file.
-
Nested Class Summary
-
Constructor Summary
ConstructorDescriptionJsFunctionParser
(Collection<String> functions, ErrorManager errorManager) Constructor -
Method Summary
Modifier and TypeMethodDescriptionParses the given file and returns the dependency information that it contained.protected boolean
Parses a line of JavaScript, extracting dependency information.Methods inherited from class com.google.javascript.jscomp.deps.JsFileLineParser
didParseSucceed, setShortcutMode
-
Constructor Details
-
JsFunctionParser
Constructor- Parameters:
functions
- Functions to parse.errorManager
- Handles parse errors.
-
-
Method Details
-
parseFile
Parses the given file and returns the dependency information that it contained.- Parameters:
filePath
- Path to the file to parse.fileContents
- The contents to parse.- Returns:
- A collection containing all symbols found in the file.
-
parseLine
protected boolean parseLine(String line) throws com.google.javascript.jscomp.deps.JsFileLineParser.ParseException Parses a line of JavaScript, extracting dependency information.- Throws:
com.google.javascript.jscomp.deps.JsFileLineParser.ParseException
-