当前位置: 首页>>代码示例>>C#>>正文


C# CSsemi类代码示例

本文整理汇总了C#中CSsemi的典型用法代码示例。如果您正苦于以下问题:C# CSsemi类的具体用法?C# CSsemi怎么用?C# CSsemi使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


CSsemi类属于命名空间,在下文中一共展示了CSsemi类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: parse

 public void parse(CSsemi.CSemiExp semi)
 {
     foreach (IRule rule in Rules)
       {
     if (rule.test(semi))
       break;
       }
       if(rule.test(semi)!=0)
        Add(rule);
 }
开发者ID:WaverV,项目名称:Projects,代码行数:10,代码来源:TestCode.cs

示例2: parse

        public void parse(CSsemi.CSemiExp semi)
        {
            // Note: rule returns true to tell parser to stop
            //       processing the current semiExp

            foreach (IRule rule in Rules)
            {
                //semi.display();
                if (rule.test(semi))
                    break;
            }
        }
开发者ID:prmk,项目名称:DependencyAnalyzer,代码行数:12,代码来源:Parser.cs

示例3: parse

        public void parse(CSsemi.CSemiExp semi, string file)        //file is passed as a parameter to insert the records filewise
        {
            // Note: rule returns true to tell parser to stop
            //       processing the current semiExp

            foreach (IRule rule in Rules)
            {
                //semi.display();
                if (rule.test(semi, file))                  //file is passed as a parameter to insert the records filewise
                    break;
            }
        }
开发者ID:WaverV,项目名称:Projects,代码行数:12,代码来源:Parser.cs

示例4: doAction

      public override void doAction(CSsemi.CSemiExp semi)
      {
          TypeModel tm = new TypeModel();
          FileModel fm = new FileModel();
          
       // Console.Write("\n  Entering scope: ");

        if (semi.Contains("class") != -1)
        {
            int index = semi.Contains("class");
           // Console.Write("class: ");
            tm.addType(semi[index + 1], fm.CurrentFile);
            

        }
        else if (semi.Contains("struct") != -1)
        {
            int index = semi.Contains("struct");
            //Console.Write("struct: ");
            tm.addType(semi[index + 1], fm.CurrentFile);
        }
        else if (semi.Contains("interface") != -1)
        {
            int index = semi.Contains("class");
            //Console.Write("interface: ");
            tm.addType(semi[index + 1], fm.CurrentFile);       
        }
        else if (semi.Contains("enum") != -1)
        {
            int index = semi.Contains("class");
            //Console.Write("enum: ");
            tm.addType(semi[index + 1], fm.CurrentFile);
        }
        else if (semi.Contains("delegte") != -1)
        {
            int index = semi.Contains("delegate");
            //Console.Write("delegate: ");
            tm.addType(semi[index + 2], fm.CurrentFile);
        }
        else

            Console.Write("");

        }
开发者ID:Logeshkumar,项目名称:Projects,代码行数:44,代码来源:TypeController.cs

示例5: doAction

 public override void doAction(CSsemi.CSemiExp semi, string filename)
 {
     Console.Write("\n  line# {0}", repo_.semi.lineCount - 1);
     this.display(semi);
 }
开发者ID:sunilkumarlakkad,项目名称:Code-Analyzer,代码行数:5,代码来源:RulesAndActions.cs

示例6: indexOfType

        public int indexOfType(CSsemi.CSemiExp semi)
        {
            int indexCL = semi.Contains("class");
              int indexIF = semi.Contains("interface");
              int indexST = semi.Contains("struct");
              int indexEN = semi.Contains("enum");

              int index = Math.Max(indexCL, indexIF);
              index = Math.Max(index, indexST);
              index = Math.Max(index, indexEN);
              return index;
        }
开发者ID:bizarreWizard,项目名称:code_analyzer_engine,代码行数:12,代码来源:IRuleandAction.cs

示例7: doAction

 public abstract void doAction(CSsemi.CSemiExp semi);
开发者ID:bizarreWizard,项目名称:code_analyzer_engine,代码行数:1,代码来源:IRuleandAction.cs

示例8: doAction

        static bool displayStack_ = false;  // default

        public abstract void doAction(CSsemi.CSemiExp semi, string filename);
开发者ID:karantech9,项目名称:Dependency-Analyzer,代码行数:3,代码来源:IRuleandAction.cs

示例9: test

 abstract public bool test(CSsemi.CSemiExp semi, string filename);
开发者ID:karantech9,项目名称:Dependency-Analyzer,代码行数:1,代码来源:IRuleandAction.cs

示例10: test

        public override bool test(CSsemi.CSemiExp semi, string filename)
        {
            if (semi[semi.count - 1] != "{")
                return false;
            int index = semi.FindFirst("(");

            List<Elem> table = RepositoryForOutput.storageForOutput_;
            CSsemi.CSemiExp local = new CSsemi.CSemiExp();
            try
            {
                if (index > 0 && !isSpecialToken(semi[index - 1]))
                {
                    for (int i = index - 1; i < semi.count; i++)
                    {
                        foreach (Elem e in table)
                        {
                            if ((e.name.Equals(semi[i])) && !(e.type.Equals("function")) && !(e.type.Equals("namespace")))
                            {
                                local.Add("Using").Add(semi[i]).Add(e.filename).Add(e.namespacename);
                                doActions(local, filename);
                                return false;
                            }
                        }
                    }
                }
            }
            catch
            {
            }
            return false;
        }
开发者ID:sunilkumarlakkad,项目名称:Dependency-Analyzer,代码行数:31,代码来源:RulesAndActions.cs

示例11: test

 public override bool test(CSsemi.CSemiExp semi)
 {
   if (semi.Contains("{") != -1)
     doActions(semi);
   return false;  // don't stop
 }
开发者ID:Logeshkumar,项目名称:Projects,代码行数:6,代码来源:TypeController.cs

示例12: display

 public override void display(CSsemi.CSemiExp semi)
 {
     Console.Write("\n    line# {0}", repo_.semi.lineCount - 1);
     Console.Write("\n    ");
     for (int i = 0; i < semi.count; ++i)
         if (semi[i] != "\n" && !semi.isComment(semi[i]))
             Console.Write("{0} ", semi[i]);
 }
开发者ID:sunilkumarlakkad,项目名称:Code-Analyzer,代码行数:8,代码来源:RulesAndActions.cs

示例13: aggregationTest

 private void aggregationTest(CSsemi.CSemiExp semi, int index, string filename, string filenameto, string namespacename)
 {
     CSsemi.CSemiExp local = new CSsemi.CSemiExp();
     if ((semi[index + 2].Equals(".")))
     {
         local.Add("Aggregation").Add(semi[index + 3]).Add(semi[index - 2]).Add(filenameto).Add(namespacename);
         doActions(local, filename);
     }
     else
     {
         local.Add("Aggregation").Add(semi[index + 1]).Add(semi[index - 2]).Add(filenameto).Add(namespacename);
         doActions(local, filename);
     }
 }
开发者ID:sunilkumarlakkad,项目名称:Dependency-Analyzer,代码行数:14,代码来源:RulesAndActions.cs

示例14: doAction

        public override void doAction(CSsemi.CSemiExp semi, string filename)
        {
            Elem elem = new Elem();
            elem.type = semi[0];  // expects type
            elem.name = semi[1];  // expects name
            elem.filename = filename;
            if (elem.type.Equals("namespace"))
                elem.namespacename = elem.name;
            else
                elem.namespacename = namespacematch();
            //repo_.stack.push(elem);
            repo_.locations.Add(elem);
            if(!elem.type.Equals("namespace"))
            RepositoryForOutput.storageForOutput_.Add(elem);

            if (AAction.displaySemi)
            {
                Console.Write("\n  line# {0,-5}", repo_.semi.lineCount - 1);
                Console.Write("entering ");
                string indent = new string(' ', 2 * repo_.stack.count);
                Console.Write("{0}", indent);
                this.display(semi); // defined in abstract action
            }
            if (AAction.displayStack)
                repo_.stack.display();

        }
开发者ID:sunilkumarlakkad,项目名称:Dependency-Analyzer,代码行数:27,代码来源:RulesAndActions.cs

示例15: inheritance

 private void inheritance(CSsemi.CSemiExp semi, string filename)
 {
     ElemRelation elem = new ElemRelation();
     elem.filenamefrom = filename;
     elem.namespacefrom = namespacematch();
     elem.definedType = semi[0];
     elem.relationType = semi[1];
     elem.fromName = semi[2];
     elem.toName = semi[3];
     elem.filenameto = semi[4];
     elem.namespaceto = semi[5];
     RepositoryForRelation.storageForRelationship_.Add(elem);
 }
开发者ID:sunilkumarlakkad,项目名称:Dependency-Analyzer,代码行数:13,代码来源:RulesAndActions.cs


注:本文中的CSsemi类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。