Skip to main content

Definition

Assembly: Microsoft.Restier.Core.dll Namespace: Microsoft.Restier.Core Inheritance: System.Object

Syntax

Summary

The default Dependency Injection container builder for Restier.

Constructors

.ctor

Initializes a new instance of the RestierContainerBuilder class.

Syntax

Parameters

Remarks

The API registrations are re-created every time because new Containers are spun up per-route. It make make more sense to create a static instance to do this, so the Dictionary is only created once.

.ctor Inherited

Inherited from object

Syntax

Methods

AddService

Adds a service of serviceType with an implementationType.

Syntax

Parameters

Returns

Type: Microsoft.OData.IContainerBuilder The IContainerBuilder instance itself.

AddService

Adds a service of serviceType with an implementationFactory.

Syntax

Parameters

Returns

Type: Microsoft.OData.IContainerBuilder The IContainerBuilder instance itself.

BuildContainer Virtual

Builds a container which implements IServiceProvider and contains all the services registered for a specific route.

Syntax

Returns

Type: System.IServiceProvider The IServiceProviderdependency injection container</see> for the registered services.

Remarks

RWM: For unit test scenarios, this container may be built without any APIs opr Routes. If you are experiencing unexpected behavior, turn on Tracing so you can see the warning messages Restier might be generating.

Equals Inherited Virtual

Inherited from object

Syntax

Parameters

Returns

Type: bool

Equals Inherited

Inherited from object

Syntax

Parameters

Returns

Type: bool

GetHashCode Inherited Virtual

Inherited from object

Syntax

Returns

Type: int

GetType Inherited

Inherited from object

Syntax

Returns

Type: System.Type

MemberwiseClone Inherited

Inherited from object

Syntax

Returns

Type: object

ReferenceEquals Inherited

Inherited from object

Syntax

Parameters

Returns

Type: bool

ToString Inherited Virtual

Inherited from object

Syntax

Returns

Type: string?
  • Microsoft.OData.IContainerBuilder