Skip to main content

Binder<TContract>.AltaRegistrationBuilder

A class in Alta.LifetimeScopes, Alta.ATT.LifetimeScopes.

VContainer registration builder used by Binder<TContract>. Builds the registration from the binder's types and lifetime, or from a bound instance.

Constructors​

MemberWhat it is
AltaRegistrationBuilder(Binder<TContract> binder)Creates a Binder from binder.

Fields​

2 private and internal fields
MemberWhat it is
private object instanceInstance set by BindToInstance, or null.
private IInstanceProvider instanceProviderInstance provider field. Not used in this class's code.

Properties​

1 private and internal property
MemberWhat it is
private Binder<TContract> Binder { get; }The binder this builder reads its types and lifetime from.

Methods​

MemberWhat it is
override Registration Build()Adds any entry point interfaces, makes sure the entry point dispatcher is registered if needed, then builds the registration.
3 private and internal methods
MemberWhat it is
internal void BindToInstance(object instance)Stores an instance so the registration always returns it.
private Registration BuildForContract()Builds a normal type registration bound to every contract type.
private Registration BuildForInstance()Builds a registration whose provider always returns the bound instance.

Used in​

Members of other types that take, return or hold a AltaRegistrationBuilder: