internal NumberRange
        (
            NumberRangesParser.ItemContext itemContext
        )
        {
            NumberRangesParser.OneContext oneContext = itemContext.one();
            if (!ReferenceEquals(oneContext, null))
            {
                string number = oneContext.NUMBER().GetText();
                Start = number;
                Stop  = number;
            }

            NumberRangesParser.RangeContext rangeContext = itemContext.range();
            if (!ReferenceEquals(rangeContext, null))
            {
                Start = rangeContext.start.Text;
                Stop  = rangeContext.stop.Text;
            }
        }
Example #2
0
 /// <summary>
 /// Exit a parse tree produced by <see cref="NumberRangesParser.one"/>.
 /// <para>The default implementation does nothing.</para>
 /// </summary>
 /// <param name="context">The parse tree.</param>
 public virtual void ExitOne([NotNull] NumberRangesParser.OneContext context)
 {
 }