public StringLiteral(StringDelimiterToken StartToken, StringLiteralText Text, StringDelimiterToken EndToken) { this.StartToken = StartToken; this.Text = Text; this.EndToken = EndToken; }
// Stream public bool TryParseStringLiteralText(Lexer lexer, out StringLiteralText result) { var list = new List <IStringLiteralTextListContent>(); while (lexer.CanReadExcept(new string[] { "\"" })) { { //if (this.TryParseStringLiteralTextToken(lexer, new string[] {"\""}, out var r)) if (this.TryParseStringLiteralTextToken(lexer, new string[] { "\"" }, out var r)) { list.Add(r); // Start from begining of the stream priority. continue; } } } result = new StringLiteralText(list); // Streams are always parsed with success. return(true); } // Parse method end