public override ExpressionNode VisitCompound_id([NotNull] mdxParser.Compound_idContext context) { if (context.children.Count > 1) { var List = context.children; var Dimension = new NumberNode(); Dimension.Value = ""; for (int i = 0; i < List.Count; i = i + 2) { NumberNode node = (NumberNode)Visit(List[i]); Dimension.Value += node.Value; } return(Dimension); } else { return(new CubeNode { CubeName = context.Start.Text }); } }
/// <summary> /// Exit a parse tree produced by <see cref="mdxParser.compound_id"/>. /// <para>The default implementation does nothing.</para> /// </summary> /// <param name="context">The parse tree.</param> public virtual void ExitCompound_id([NotNull] mdxParser.Compound_idContext context) { }
/// <summary> /// Visit a parse tree produced by <see cref="mdxParser.compound_id"/>. /// <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 VisitCompound_id([NotNull] mdxParser.Compound_idContext context) { return(VisitChildren(context)); }