Esempio n. 1
0
 public MDXGrammarYaccClass(MDXParamParser paramparser, SSYaccTable q_table, SSLex q_lex) : base(q_table, q_lex)
 {
     this.m_ParamParser = paramparser;
     this.m_Errors      = new MessageCollection();
     this.m_StopWatch   = new Stopwatch();
     this.m_Cancel      = false;
 }
Esempio n. 2
0
        private void Parse(bool ColorCode)
        {
            string mDX = this.m_MDX;

            this.m_ParamParser = new MDXParamParser();
            mDX = this.m_ParamParser.ParseParameters(mDX);
            ColorCoding        coding = new ColorCoding();
            MDXGrammarLexClass class2 = new MDXGrammarLexClass(new MDXGrammarLexTable(), new SSLexStringConsumer(mDX))
            {
                m_Source      = this.m_Source,
                m_ColorCoding = coding
            };

            this.m_SSParser = new MDXGrammarYaccClass(this.m_ParamParser, new MDXGrammarYaccTable(), class2);
            this.m_SSParser.m_ColorCodeOnly = ColorCode;
            this.m_SSParser.m_ColorCoding   = coding;
            this.m_SSParser.SetMdxText(mDX);
            this.m_SSParser.SetMetadataInfo(this.m_CubeInfo);
            this.m_SSParser.m_Source = this.m_Source;
            Stopwatch stopwatch = new Stopwatch();

            stopwatch.Start();
            if (!this.m_Cancel)
            {
                bool flag = this.m_SSParser.parse();
                if (!this.m_Cancel)
                {
                    stopwatch.Stop();
                    if (flag)
                    {
                        //throw new MDXParserException(this.m_SSParser.m_Errors);
                    }
                    if (class2.Comments.Count > 0)
                    {
                        this.m_PostComments          = new MDXEmptyNode();
                        this.m_PostComments.Comments = class2.Comments;
                        class2.Comments = null;
                    }
                    if (this.m_ParamParser.m_Params.Count > 0)
                    {
                        this.GetNode();
                        MDXSelectNode select = this.GetSelect();
                        if (select != null)
                        {
                            select.m_Params = this.m_ParamParser.m_Params;
                        }
                    }
                }
            }
        }