Beispiel #1
0
 internal MemberInfo[] LookupNamedMembers(string MemberName)
 {
     MemberInfo[] Members;
     if (Symbols.IsGenericParameter(this.m_Type))
     {
         Type classConstraint = Symbols.GetClassConstraint(this.m_Type);
         Members = classConstraint == null ? (MemberInfo[])null : classConstraint.GetMember(MemberName, BindingFlags.IgnoreCase | BindingFlags.Instance | BindingFlags.Static | BindingFlags.Public | BindingFlags.FlattenHierarchy);
     }
     else
     {
         Members = this.m_IReflect.GetMember(MemberName, BindingFlags.IgnoreCase | BindingFlags.Instance | BindingFlags.Static | BindingFlags.Public | BindingFlags.FlattenHierarchy);
     }
     MemberInfo[] memberInfoArray = Symbols.Container.FilterInvalidMembers(Members);
     if (memberInfoArray == null)
     {
         memberInfoArray = Symbols.Container.NoMembers;
     }
     else if (memberInfoArray.Length > 1)
     {
         Array.Sort((Array)memberInfoArray, (IComparer)Symbols.Container.InheritanceSorter.Instance);
     }
     return(memberInfoArray);
 }