Search Results for

    Show / Hide Table of Contents
    View Source

    Class ServiceFactoryExtensions

    Extensions for ServiceFactory.

    Inheritance
    System.Object
    Namespace: Umbraco.Cms.Core.Events
    Assembly: Umbraco.Core.dll
    Syntax
    public static class ServiceFactoryExtensions

    Methods

    View Source

    GetInstance<T>(ServiceFactory)

    Gets an instance of T.

    Declaration
    public static T GetInstance<T>(this ServiceFactory factory)
    Parameters
    Type Name Description
    ServiceFactory factory

    The service factory.

    Returns
    Type Description
    T

    The new instance.

    Type Parameters
    Name Description
    T

    The type to return.

    View Source

    GetInstances<T>(ServiceFactory)

    Gets a collection of instances of T.

    Declaration
    public static IEnumerable<T> GetInstances<T>(this ServiceFactory factory)
    Parameters
    Type Name Description
    ServiceFactory factory

    The service factory.

    Returns
    Type Description
    IEnumerable<T>

    The new instance collection.

    Type Parameters
    Name Description
    T

    The collection item type to return.

    • Improve this Doc
    • View Source
    In This Article
    • Methods
      • GetInstance<T>(ServiceFactory)
      • GetInstances<T>(ServiceFactory)
    Back to top Copyright © 2016-present Umbraco
    Generated by DocFX