Ejemplo n.º 1
0
        public void CollectDerivedElements(RuleDeclaration ruleDeclaration)
        {
            ICollection <ITypeElement> classes =
                GetPsiServices().CacheManager.GetDeclarationsCache(GetPsiModule(), false, true).GetTypeElementsByCLRName(
                    myParserPackageName + "." + myParserClassName);
            ICollection <ITypeElement> visitorClasses = CollectVisitorClasses();
            IEnumerator <ITypeElement> enumerator     = classes.GetEnumerator();

            if (enumerator.MoveNext())
            {
                ruleDeclaration.CollectDerivedDeclaredElements((IClass)enumerator.Current, visitorClasses, myTreeInterfacesPackageName, myTreeClassesPackageName, myInterfacePrefix, myVisitorMethodPrefix, myVisitorMethodSuffix);
            }
        }
Ejemplo n.º 2
0
 public void CollectDerivedElements(RuleDeclaration ruleDeclaration)
 {
   ICollection<ITypeElement> classes =
     GetPsiServices().CacheManager.GetDeclarationsCache(GetPsiModule(), false, true).GetTypeElementsByCLRName(
       myParserPackageName + "." + myParserClassName);
   ICollection<ITypeElement> visitorClasses = CollectVisitorClasses();
   IEnumerator<ITypeElement> enumerator = classes.GetEnumerator();
   if (enumerator.MoveNext())
   {
     ruleDeclaration.CollectDerivedDeclaredElements((IClass)enumerator.Current, visitorClasses, myTreeInterfacesPackageName, myTreeClassesPackageName, myInterfacePrefix, myVisitorMethodPrefix, myVisitorMethodSuffix);
   }
 }