Search Results for

    Show / Hide Table of Contents

    Class ServiceProviderDependencyResolver

    INTERNAL API.

    IDependencyResolver implementation backed by IServiceProvider

    Inheritance
    object
    ServiceProviderDependencyResolver
    Implements
    IDependencyResolver
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Akka.DependencyInjection
    Assembly: Akka.DependencyInjection.dll
    Syntax
    public class ServiceProviderDependencyResolver : IDependencyResolver

    Constructors

    | Edit this page View Source

    ServiceProviderDependencyResolver(IServiceProvider)

    Declaration
    public ServiceProviderDependencyResolver(IServiceProvider serviceProvider)
    Parameters
    Type Name Description
    IServiceProvider serviceProvider

    Properties

    | Edit this page View Source

    ServiceProvider

    Declaration
    public IServiceProvider ServiceProvider { get; }
    Property Value
    Type Description
    IServiceProvider

    Methods

    | Edit this page View Source

    CreateScope()

    Declaration
    public IResolverScope CreateScope()
    Returns
    Type Description
    IResolverScope
    | Edit this page View Source

    GetService(Type)

    Declaration
    public object GetService(Type type)
    Parameters
    Type Name Description
    Type type
    Returns
    Type Description
    object
    | Edit this page View Source

    GetService<T>()

    Declaration
    public T GetService<T>()
    Returns
    Type Description
    T
    Type Parameters
    Name Description
    T
    | Edit this page View Source

    Props(Type)

    Used to dynamically instantiate an actor where some of the constructor arguments are populated via dependency injection and others are not.

    Declaration
    public Props Props(Type type)
    Parameters
    Type Name Description
    Type type

    The type of actor to instantiate.

    Returns
    Type Description
    Props

    A new Props instance which uses DI internally.

    Remarks

    YOU ARE RESPONSIBLE FOR MANAGING THE LIFECYCLE OF YOUR OWN DEPENDENCIES. AKKA.NET WILL NOT ATTEMPT TO DO IT FOR YOU.

    | Edit this page View Source

    Props(Type, params object[])

    Used to dynamically instantiate an actor where some of the constructor arguments are populated via dependency injection and others are not.

    Declaration
    public Props Props(Type type, params object[] args)
    Parameters
    Type Name Description
    Type type

    The type of actor to instantiate.

    object[] args

    Optional. Any constructor arguments that will be passed into the actor's constructor directly without being resolved by DI first.

    Returns
    Type Description
    Props

    A new Props instance which uses DI internally.

    Remarks

    YOU ARE RESPONSIBLE FOR MANAGING THE LIFECYCLE OF YOUR OWN DEPENDENCIES. AKKA.NET WILL NOT ATTEMPT TO DO IT FOR YOU.

    | Edit this page View Source

    Props<T>(params object[])

    Used to dynamically instantiate an actor where some of the constructor arguments are populated via dependency injection and others are not.

    Declaration
    public Props Props<T>(params object[] args) where T : ActorBase
    Parameters
    Type Name Description
    object[] args

    Optional. Any constructor arguments that will be passed into the actor's constructor directly without being resolved by DI first.

    Returns
    Type Description
    Props

    A new Props instance which uses DI internally.

    Type Parameters
    Name Description
    T

    The type of actor to instantiate.

    Remarks

    YOU ARE RESPONSIBLE FOR MANAGING THE LIFECYCLE OF YOUR OWN DEPENDENCIES. AKKA.NET WILL NOT ATTEMPT TO DO IT FOR YOU.

    Implements

    IDependencyResolver

    Extension Methods

    ObjectExtensions.IsDefaultForType<T>(T)
    ObjectExtensions.AsOption<T>(T)
    Extensions.AsInstanceOf<T>(object)
    In this article
    • githubEdit this page
    • View Source
    Back to top
    Contribute
    • Project Chat
    • Discussion Forum
    • Source Code
    Support
    • Akka.NET Support Plans
    • Akka.NET Observability Tools
    • Akka.NET Training & Consulting
    Maintained By
    • Petabridge - The Akka.NET Company
    • Learn Akka.NET