public static Template Parse(string text, string sourceFilePath = null, ParserOptions?parserOptions = null, LexerOptions?lexerOptions = null) { var template = new Template(parserOptions, lexerOptions, sourceFilePath); template.ParseInternal(text, sourceFilePath); return(template); }
/// <summary> /// Parses the specified scripting text into a <see cref="Template"/> . /// </summary> /// <param name="text">The scripting text.</param> /// <param name="sourceFilePath">The source file path. Optional, used for better error reporting if the source file has a location on the disk</param> /// <param name="options">The templating parsing options.</param> /// <returns>A template</returns> public static Template Parse(string text, string sourceFilePath = null, ParserOptions options = null) { var template = new Template(options, sourceFilePath); template.ParseInternal(text, sourceFilePath); return template; }