Beispiel #1
0
        public static IEnumerable <TreeValue <TypeValueInfo> > GetAllValuesInfos(Type type, MemberType memberType = MemberType.Instance | MemberType.Public | MemberType.Field | MemberType.Property,
                                                                                 TypeReflectionOptions options    = TypeReflectionOptions.ValueType | TypeReflectionOptions.NotValueType, Func <TypeValueInfo, TreeFilter> filter = null)
        {
            TypeReflection typeReflection = new TypeReflection();

            typeReflection._bindingFlags = GetBindingFlags(memberType);
            typeReflection._memberTypes  = GetMemberTypes(memberType);
            typeReflection._filter       = filter;
            //typeReflection._verbose = verbose;
            if ((options & TypeReflectionOptions.Source) == TypeReflectionOptions.Source)
            {
                typeReflection._returnSource = true;
            }
            if ((options & TypeReflectionOptions.Parent) == TypeReflectionOptions.Parent)
            {
                typeReflection._returnParent = true;
            }
            if ((options & TypeReflectionOptions.ValueType) == TypeReflectionOptions.ValueType)
            {
                typeReflection._returnValueType = true;
            }
            if ((options & TypeReflectionOptions.NotValueType) == TypeReflectionOptions.NotValueType)
            {
                typeReflection._returnNotValueType = true;
            }
            return(typeReflection._GetAllValuesInfos(type));
        }
Beispiel #2
0
 public static IEnumerable<TreeValue<TypeValueInfo>> zGetTypeAllValuesInfos(this Type type, MemberType memberType = MemberType.Instance | MemberType.Public | MemberType.Field | MemberType.Property,
     TypeReflectionOptions options = TypeReflectionOptions.ValueType | TypeReflectionOptions.NotValueType, Func<TypeValueInfo, TreeFilter> filter = null)
 {
     return TypeReflection.GetAllValuesInfos(type, memberType, options, filter);
 }
Beispiel #3
0
 public static IEnumerable<TreeValue<TypeValueInfo>> GetAllValuesInfos(Type type, MemberType memberType = MemberType.Instance | MemberType.Public | MemberType.Field | MemberType.Property,
     TypeReflectionOptions options = TypeReflectionOptions.ValueType | TypeReflectionOptions.NotValueType, Func<TypeValueInfo, TreeFilter> filter = null)
 {
     TypeReflection typeReflection = new TypeReflection();
     typeReflection._bindingFlags = GetBindingFlags(memberType);
     typeReflection._memberTypes = GetMemberTypes(memberType);
     typeReflection._filter = filter;
     //typeReflection._verbose = verbose;
     if ((options & TypeReflectionOptions.Source) == TypeReflectionOptions.Source)
         typeReflection._returnSource = true;
     if ((options & TypeReflectionOptions.Parent) == TypeReflectionOptions.Parent)
         typeReflection._returnParent = true;
     if ((options & TypeReflectionOptions.ValueType) == TypeReflectionOptions.ValueType)
         typeReflection._returnValueType = true;
     if ((options & TypeReflectionOptions.NotValueType) == TypeReflectionOptions.NotValueType)
         typeReflection._returnNotValueType = true;
     return typeReflection._GetAllValuesInfos(type);
 }
Beispiel #4
0
 public static IEnumerable <TreeValue <TypeValueInfo> > zGetTypeAllValuesInfos(this Type type, MemberType memberType = MemberType.Instance | MemberType.Public | MemberType.Field | MemberType.Property,
                                                                               TypeReflectionOptions options         = TypeReflectionOptions.ValueType | TypeReflectionOptions.NotValueType, Func <TypeValueInfo, TreeFilter> filter = null)
 {
     return(TypeReflection.GetAllValuesInfos(type, memberType, options, filter));
 }