Stashbox by Peter Csajtai

<PackageReference Include="Stashbox" Version="3.1.0-preview-537" />

 IFluentServiceConfigurator<TConfigurator>

public interface IFluentServiceConfigurator<TConfigurator> : IBaseFluentConfigurator<TConfigurator> where TConfigurator : IFluentServiceConfigurator<TConfigurator>
Represents the fluent service registraton api.
TConfigurator AsImplementedTypes()

Registers the given service by all of it's implemented types.

TConfigurator AsServiceAlso(Type serviceType)

Binds the currently configured registration to an additional service type.

TConfigurator DefinesScope(object scopeName = null)

It means this registration would be used as a logical scope for it's dependencies, the dependencies registered with the InNamedScope and with the same name as it's param will be preffered during reolution.

TConfigurator InNamedScope(object scopeName)

Sets a scope name condition for the registration, it will be used only when a scope with the given name requests it.

TConfigurator InScopeDefinedBy(Type type)

Sets a condition for the registration that it will be used only within the scope defined by the given type.

TConfigurator InScopeDefinedBy<TScopeDefiner>()

Sets a condition for the registration that it will be used only within the scope defined by the given type.

TConfigurator SetImplementationType(Type implementationType)

Sets the current registration's implementation type.

TConfigurator When(Func<TypeInformation, bool> resolutionCondition)

Sets a generic condition for the registration.

TConfigurator WhenDependantIs<TTarget>()

Sets a parent target condition for the registration.

TConfigurator WhenDependantIs(Type targetType)

Sets a parent target condition for the registration.

TConfigurator WhenHas<TAttribute>() where TAttribute : Attribute

Sets an attribute condition for the registration.

TConfigurator WhenHas(Type attributeType)

Sets an attribute condition for the registration.

TConfigurator WithFactory(Func<object> singleFactory, bool isCompiledLambda = false)

Sets a parameterless factory delegate for the registration.

TConfigurator WithFactory(Func<IDependencyResolver, object> containerFactory, bool isCompiledLambda = false)

Sets a container factory delegate for the registration.

TConfigurator WithInstance(object instance, bool wireUp = false)

Sets an instance as the resolution target of the registration.

TConfigurator WithLifetime(LifetimeDescriptor lifetime)

Sets the lifetime of the registration.

TConfigurator WithName(object name)

Sets the name of the registration.

Sets the lifetime to ResolutionRequestLifetime. The container will inject this registration in a singleton per resolution request manner.

TConfigurator WithScopedLifetime()

Sets a scoped lifetime for the registration.

TConfigurator WithSingletonLifetime()

Sets a singleton lifetime for the registration.