Catel.Core by GeertvanHorrik

<PackageReference Include="Catel.Core" Version="4.1.0-unstable0129" />

 ReflectionExtensions

public static class ReflectionExtensions
Reflection extension class.
public static bool ContainsGenericParametersEx(this Type type)

Determines whether the specified type contains generic parameters.

public static Assembly GetAssemblyEx(this Type type)

The get assembly ex.

public static string GetAssemblyFullNameEx(this Type type)

The get assembly full name ex.

public static Type GetBaseTypeEx(this Type type)

The get base type ex.

public static ConstructorInfo GetConstructorEx(this Type type, Type[] types)

The get constructor ex.

public static ConstructorInfo[] GetConstructorsEx(this Type type)

The get constructors ex.

public static Attribute GetCustomAttributeEx(this Assembly assembly, Type attributeType)

public static Attribute GetCustomAttributeEx(this MethodInfo methodInfo, Type attributeType, bool inherit)

public static Attribute GetCustomAttributeEx(this PropertyInfo propertyInfo, Type attributeType, bool inherit)

public static Attribute GetCustomAttributeEx(this Type type, Type attributeType, bool inherit)

The get custom attribute ex.

public static Attribute[] GetCustomAttributesEx(this Assembly assembly, Type attributeType)

public static Attribute[] GetCustomAttributesEx(this MethodInfo methodInfo, bool inherit)

public static Attribute[] GetCustomAttributesEx(this MethodInfo methodInfo, Type attributeType, bool inherit)

public static Attribute[] GetCustomAttributesEx(this PropertyInfo propertyInfo, bool inherit)

public static Attribute[] GetCustomAttributesEx(this PropertyInfo propertyInfo, Type attributeType, bool inherit)

public static Attribute[] GetCustomAttributesEx(this Type type, bool inherit)

The get custom attributes ex.

public static Attribute[] GetCustomAttributesEx(this Type type, Type attributeType, bool inherit)

The get custom attributes ex.

public static EventInfo GetEventEx(this Type type, string name, bool flattenHierarchy = true, bool allowStaticMembers = false)

The get event ex.

public static EventInfo GetEventEx(this Type type, string name, BindingFlags bindingFlags)

The get event ex.

public static EventInfo[] GetEventsEx(this Type type, bool flattenHierarchy = true, bool allowStaticMembers = false)

The get events ex.

public static FieldInfo GetFieldEx(this Type type, string name, bool flattenHierarchy = true, bool allowStaticMembers = false)

The get field ex.

public static FieldInfo GetFieldEx(this Type type, string name, BindingFlags bindingFlags)

The get field ex.

public static FieldInfo[] GetFieldsEx(this Type type, bool flattenHierarchy = true, bool allowStaticMembers = false)

The get fields ex.

public static FieldInfo[] GetFieldsEx(this Type type, BindingFlags bindingFlags)

The get fields ex.

public static Type[] GetGenericArgumentsEx(this Type type)

The get generic arguments ex.

public static Type GetGenericTypeDefinitionEx(this Type type)

Gets the generic type definition of the specified type.

public static Type[] GetInterfacesEx(this Type type)

The get interfaces ex.

public static MethodInfo GetMethodEx(this Type type, string name, bool flattenHierarchy = true, bool allowStaticMembers = false)

The get method ex.

public static MethodInfo GetMethodEx(this Type type, string name, BindingFlags bindingFlags)

The get method ex.

public static MethodInfo GetMethodEx(this Type type, string name, Type[] types, bool flattenHierarchy = true, bool allowStaticMembers = false)

The get method ex.

public static MethodInfo GetMethodEx(this Type type, string name, Type[] types, BindingFlags bindingFlags)

The get method ex.

public static MethodInfo[] GetMethodsEx(this Type type, bool flattenHierarchy = true, bool allowStaticMembers = false)

The get methods ex.

public static MethodInfo[] GetMethodsEx(this Type type, BindingFlags bindingFlags)

The get methods ex.

public static IEnumerable<Type> GetParentTypes(this Type type)

Gets the parent types.

public static PropertyInfo[] GetPropertiesEx(this Type type, bool flattenHierarchy = true, bool allowStaticMembers = false)

The get properties ex.

public static PropertyInfo[] GetPropertiesEx(this Type type, BindingFlags bindingFlags)

The get properties ex.

public static PropertyInfo GetPropertyEx(this Type type, string name, bool flattenHierarchy = true, bool allowStaticMembers = false, bool allowExplicitInterfaceProperties = true)

The get property ex.

public static PropertyInfo GetPropertyEx(this Type type, string name, BindingFlags bindingFlags, bool allowExplicitInterfaceProperties = true)

The get property ex.

public static string GetSafeFullName(this Type type)

Gets the full name of the type in a safe way. This means it checks for null first.

public static Type[] GetTypesEx(this Assembly assembly)

public static bool HasBaseTypeEx(this Type type, Type typeToCheck)

The has base type ex.

public static bool ImplementsInterfaceEx<TInterface>(this Type type)

Returns whether the specified type implements the specified interface.

public static bool ImplementsInterfaceEx(this Type type, Type interfaceType)

Returns whether the specified type implements the specified interface.

public static bool IsAbstractEx(this Type type)

Determines whether the specified type is abstract.

public static bool IsAssignableFromEx(this Type type, Type typeToCheck)

The is assignable from ex.

public static bool IsClassEx(this Type type)

Determines whether the specified type is a class.

public static bool IsCOMObjectEx(this Type type)

Determines whether the specified type is a COM object.

public static bool IsEnumEx(this Type type)

The is enum ex.

public static bool IsGenericTypeEx(this Type type)

The is generic type ex.

public static bool IsInstanceOfTypeEx(this Type type, object objectToCheck)

The is instance of type ex.

public static bool IsInterfaceEx(this Type type)

The is interface ex.

public static bool IsNestedPublicEx(this Type type)

The is nested public ex.

public static bool IsPrimitiveEx(this Type type)

Returns whether the specified type is a primitive type.

public static bool IsPublicEx(this Type type)

The is public ex.

public static bool IsSerializableEx(this Type type)

The is serializable ex.

public static bool IsValueTypeEx(this Type type)

The is value type ex.