Search Results for

    Show / Hide Table of Contents
    View Source

    Class TypeFinderExtensions

    Inheritance
    System.Object
    Namespace: Umbraco.Extensions
    Assembly: Umbraco.Core.dll
    Syntax
    public static class TypeFinderExtensions

    Methods

    View Source

    FindClassesOfType<T>(ITypeFinder, Nullable<IEnumerable<Assembly>>, Boolean)

    Returns all types found of in the assemblies specified of type T

    Declaration
    public static IEnumerable<Type> FindClassesOfType<T>(this ITypeFinder typeFinder, IEnumerable<Assembly>? assemblies = null, bool onlyConcreteClasses = true)
    Parameters
    Type Name Description
    ITypeFinder typeFinder
    System.Nullable<IEnumerable<System.Reflection.Assembly>> assemblies
    System.Boolean onlyConcreteClasses
    Returns
    Type Description
    IEnumerable<Type>
    Type Parameters
    Name Description
    T
    View Source

    FindClassesOfTypeWithAttribute<T, TAttribute>(ITypeFinder, Nullable<IEnumerable<Assembly>>, Boolean)

    Finds any classes derived from the type T that contain the attribute TAttribute

    Declaration
    public static IEnumerable<Type> FindClassesOfTypeWithAttribute<T, TAttribute>(this ITypeFinder typeFinder, IEnumerable<Assembly>? assemblies = null, bool onlyConcreteClasses = true)
        where TAttribute : Attribute
    Parameters
    Type Name Description
    ITypeFinder typeFinder
    System.Nullable<IEnumerable<System.Reflection.Assembly>> assemblies
    System.Boolean onlyConcreteClasses
    Returns
    Type Description
    IEnumerable<Type>
    Type Parameters
    Name Description
    T
    TAttribute
    View Source

    FindClassesWithAttribute<T>(ITypeFinder, Nullable<IEnumerable<Assembly>>, Boolean)

    Finds the classes with attribute.

    Declaration
    public static IEnumerable<Type> FindClassesWithAttribute<T>(this ITypeFinder typeFinder, IEnumerable<Assembly>? assemblies = null, bool onlyConcreteClasses = true)
        where T : Attribute
    Parameters
    Type Name Description
    ITypeFinder typeFinder
    System.Nullable<IEnumerable<System.Reflection.Assembly>> assemblies

    The assemblies.

    System.Boolean onlyConcreteClasses

    if set to true only concrete classes.

    Returns
    Type Description
    IEnumerable<Type>
    Type Parameters
    Name Description
    T
    • Improve this Doc
    • View Source
    In This Article
    • Methods
      • FindClassesOfType<T>(ITypeFinder, Nullable<IEnumerable<Assembly>>, Boolean)
      • FindClassesOfTypeWithAttribute<T, TAttribute>(ITypeFinder, Nullable<IEnumerable<Assembly>>, Boolean)
      • FindClassesWithAttribute<T>(ITypeFinder, Nullable<IEnumerable<Assembly>>, Boolean)
    Back to top Copyright © 2016-present Umbraco
    Generated by DocFX