Search in sources :

Example 1 with SoyFileSetParserBuilder

use of com.google.template.soy.SoyFileSetParserBuilder in project closure-templates by google.

the class JsSrcSubject method parse.

private ParseResult parse() {
    SoyFileSetParserBuilder builder = SoyFileSetParserBuilder.forFileContents(actual()).allowUnboundGlobals(true).declaredSyntaxVersion(syntaxVersion).typeRegistry(typeRegistry).options(generalOptions);
    for (SoyFunction soyFunction : soyFunctions) {
        builder.addSoyFunction(soyFunction);
    }
    ParseResult parse = builder.parse();
    // genjscodevisitor depends on this having been run
    return parse;
}
Also used : SoyFileSetParserBuilder(com.google.template.soy.SoyFileSetParserBuilder) ParseResult(com.google.template.soy.SoyFileSetParser.ParseResult) SoyFunction(com.google.template.soy.shared.restricted.SoyFunction)

Aggregations

ParseResult (com.google.template.soy.SoyFileSetParser.ParseResult)1 SoyFileSetParserBuilder (com.google.template.soy.SoyFileSetParserBuilder)1 SoyFunction (com.google.template.soy.shared.restricted.SoyFunction)1