Example #1
0
        public override void ExitCombine(VmstatsParser.CombineContext context)
        {
            Console.WriteLine("ExitCombine");

            // Remove this Combines id from the queue as it is not needed anymore and reset all the combine
            // variables
            currentCombineID.Dequeue();
            numberTransformPipelinesInCombine = 0;
            inCombine = false;
        }
Example #2
0
        public override void EnterCombine(VmstatsParser.CombineContext context)
        {
            Console.WriteLine("EnterCombine");

            // Determine the number of transform pipelines in this combine. Remove 2 for the braces.
            // Divide by 2 and then round up, to account for the + between each transform
            var count = context.ChildCount;

            numberTransformPipelinesInCombine = ((count - 2) / 2) + 1;

            // Create a new id for this combine, so all transforms created from now will contain this id
            currentCombineID.Enqueue(Guid.NewGuid());
            inCombine = true;
        }
Example #3
0
 /// <summary>
 /// Exit a parse tree produced by <see cref="VmstatsParser.combine"/>.
 /// <para>The default implementation does nothing.</para>
 /// </summary>
 /// <param name="context">The parse tree.</param>
 public virtual void ExitCombine([NotNull] VmstatsParser.CombineContext context)
 {
 }
 /// <summary>
 /// Visit a parse tree produced by <see cref="VmstatsParser.combine"/>.
 /// <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 VisitCombine([NotNull] VmstatsParser.CombineContext context)
 {
     return(VisitChildren(context));
 }