ConstructorInfo[] GetConstructorsInternal (BindingFlags bf, MonoGenericClass reftype)
{
ConstructorInfo[] ctors = GetConstructorsFromGTDWithHint (bf);
if (ctors == null || ctors.Length == 0)
return new ConstructorInfo [0];
ArrayList l = new ArrayList ();
bool match;
MethodAttributes mattrs;
initialize ();
for (int i = 0; i < ctors.Length; i++) {
ConstructorInfo c = ctors [i];
match = false;
mattrs = c.Attributes;
if ((mattrs & MethodAttributes.MemberAccessMask) == MethodAttributes.Public) {
if ((bf & BindingFlags.Public) != 0)
match = true;
} else {
if ((bf & BindingFlags.NonPublic) != 0)
match = true;
}
if (!match)
continue;
match = false;
if ((mattrs & MethodAttributes.Static) != 0) {
if ((bf & BindingFlags.Static) != 0)
match = true;
} else {
if ((bf & BindingFlags.Instance) != 0)
match = true;
}
if (!match)
continue;
l.Add (TypeBuilder.GetConstructor (this, c));
}
ConstructorInfo[] result = new ConstructorInfo [l.Count];
l.CopyTo (result);
return result;
}