ODataConventionModelBuilder Constructors

Definition

Overloads

ODataConventionModelBuilder()

Initializes a new instance of the ODataConventionModelBuilder class.

ODataConventionModelBuilder(ApplicationPartManager)

Initializes a new instance of the ODataConventionModelBuilder class. This constructor uses the ApplicationPartManager from AspNetCore to get a list of assemblies for modeling.

ODataConventionModelBuilder(IServiceProvider)

Initializes a new instance of the ODataConventionModelBuilder class. This constructor uses the ApplicationPartManager from AspNetCore obtained from the IServiceProvider to get a list of assemblies for modeling.

ODataConventionModelBuilder(HttpConfiguration)

Initializes a new instance of the ODataConventionModelBuilder class.

ODataConventionModelBuilder(IServiceProvider, Boolean)

Initializes a new instance of the ODataConventionModelBuilder class. This constructor uses the ApplicationPartManager from AspNetCore obtained from the IServiceProvider to get a list of assemblies for modeling. The model built if isQueryCompositionMode is true has more relaxed inference rules and also treats all types as entity types. This constructor is intended for use by unit testing only.

ODataConventionModelBuilder(HttpConfiguration, Boolean)

Initializes a new instance of the ODataConventionModelBuilder class.

ODataConventionModelBuilder()

Initializes a new instance of the ODataConventionModelBuilder class.

public ODataConventionModelBuilder ();
Public Sub New ()

Remarks

This constructor will work stand-alone scenarios but it does require using the System.Web.Http.Dispatcher.DefaultAssembliesResolver to get a list of assemblies to build the model.

Applies to

ODataConventionModelBuilder(ApplicationPartManager)

Initializes a new instance of the ODataConventionModelBuilder class. This constructor uses the ApplicationPartManager from AspNetCore to get a list of assemblies for modeling.

public ODataConventionModelBuilder (Microsoft.AspNetCore.Mvc.ApplicationParts.ApplicationPartManager applicationPartManager);
new Microsoft.AspNet.OData.Builder.ODataConventionModelBuilder : Microsoft.AspNetCore.Mvc.ApplicationParts.ApplicationPartManager -> Microsoft.AspNet.OData.Builder.ODataConventionModelBuilder
Public Sub New (applicationPartManager As ApplicationPartManager)

Parameters

applicationPartManager
ApplicationPartManager

The application part manager to use.

Remarks

This function uses types that are AspNetCore-specific.

Applies to

ODataConventionModelBuilder(IServiceProvider)

Initializes a new instance of the ODataConventionModelBuilder class. This constructor uses the ApplicationPartManager from AspNetCore obtained from the IServiceProvider to get a list of assemblies for modeling.

public ODataConventionModelBuilder (IServiceProvider provider);
new Microsoft.AspNet.OData.Builder.ODataConventionModelBuilder : IServiceProvider -> Microsoft.AspNet.OData.Builder.ODataConventionModelBuilder
Public Sub New (provider As IServiceProvider)

Parameters

provider
IServiceProvider

The service provider to use.

Applies to

ODataConventionModelBuilder(HttpConfiguration)

Initializes a new instance of the ODataConventionModelBuilder class.

public ODataConventionModelBuilder (System.Web.Http.HttpConfiguration configuration);
new Microsoft.AspNet.OData.Builder.ODataConventionModelBuilder : System.Web.Http.HttpConfiguration -> Microsoft.AspNet.OData.Builder.ODataConventionModelBuilder
Public Sub New (configuration As HttpConfiguration)

Parameters

configuration
System.Web.Http.HttpConfiguration

The System.Web.Http.HttpConfiguration to use.

Remarks

This function uses types that are AspNet-specific.

Applies to

ODataConventionModelBuilder(IServiceProvider, Boolean)

Initializes a new instance of the ODataConventionModelBuilder class. This constructor uses the ApplicationPartManager from AspNetCore obtained from the IServiceProvider to get a list of assemblies for modeling. The model built if isQueryCompositionMode is true has more relaxed inference rules and also treats all types as entity types. This constructor is intended for use by unit testing only.

public ODataConventionModelBuilder (IServiceProvider provider, bool isQueryCompositionMode);
new Microsoft.AspNet.OData.Builder.ODataConventionModelBuilder : IServiceProvider * bool -> Microsoft.AspNet.OData.Builder.ODataConventionModelBuilder
Public Sub New (provider As IServiceProvider, isQueryCompositionMode As Boolean)

Parameters

provider
IServiceProvider

The service provider to use.

isQueryCompositionMode
Boolean

If the model is being built for only querying.

Applies to

ODataConventionModelBuilder(HttpConfiguration, Boolean)

Initializes a new instance of the ODataConventionModelBuilder class.

public ODataConventionModelBuilder (System.Web.Http.HttpConfiguration configuration, bool isQueryCompositionMode);
new Microsoft.AspNet.OData.Builder.ODataConventionModelBuilder : System.Web.Http.HttpConfiguration * bool -> Microsoft.AspNet.OData.Builder.ODataConventionModelBuilder
Public Sub New (configuration As HttpConfiguration, isQueryCompositionMode As Boolean)

Parameters

configuration
System.Web.Http.HttpConfiguration

The System.Web.Http.HttpConfiguration to use.

isQueryCompositionMode
Boolean

If the model is being built for only querying.

Remarks

The model built if isQueryCompositionMode is true has more relaxed inference rules and also treats all types as entity types. This constructor is intended for use by unit testing only.

Applies to