/// <summary>
	/// Exit a parse tree produced by the <c>wordRangeStartToEnd</c>
	/// labeled alternative in <see cref="UserAgentTreeWalkerParser.wordRange"/>.
	/// <para>The default implementation does nothing.</para>
	/// </summary>
	/// <param name="context">The parse tree.</param>
	public virtual void ExitWordRangeStartToEnd([NotNull] UserAgentTreeWalkerParser.WordRangeStartToEndContext context) { }
示例#2
0
 /// <summary>
 /// Visits a word range from first to last word.
 /// </summary>
 /// <param name="context">The context<see cref="UserAgentTreeWalkerParser.WordRangeStartToEndContext"/>.</param>
 /// <returns>The resulting <see cref="Range"/>.</returns>
 public override Range VisitWordRangeStartToEnd([NotNull] UserAgentTreeWalkerParser.WordRangeStartToEndContext context)
 {
     return(new Range(int.Parse(context.firstWord.Text), int.Parse(context.lastWord.Text)));
 }
 /// <summary>
 /// Visit a parse tree produced by the <c>wordRangeStartToEnd</c>
 /// labeled alternative in <see cref="UserAgentTreeWalkerParser.wordRange"/>.
 /// <para>
 /// The default implementation returns the result of calling <see cref="AbstractParseTreeVisitor{Result}.VisitChildren(IRuleNode)"/>
 /// on <paramref name="context"/>.
 /// </para>
 /// </summary>
 /// <param name="context">The parse tree.</param>
 /// <return>The visitor result.</return>
 public virtual Result VisitWordRangeStartToEnd([NotNull] UserAgentTreeWalkerParser.WordRangeStartToEndContext context)
 {
     return(VisitChildren(context));
 }