DatabaseProvider<TProviderServices, TOptionsExtension> DatabaseProvider(Of TProviderServices, TOptionsExtension) Class

The primary point where a database provider can tell EF that it has been selected for the current context and provide the services required for it to function.

This type is typically used by database providers (and other extensions). It is generally not used in application code.

Syntax

Declaration

public class DatabaseProvider<TProviderServices, TOptionsExtension> : IDatabaseProvider where TProviderServices : class, IDatabaseProviderServices where TOptionsExtension : class, IDbContextOptionsExtensionPublic Class DatabaseProvider(Of TProviderServices As {Class, IDatabaseProviderServices}, TOptionsExtension As {Class, IDbContextOptionsExtension})
    Implements IDatabaseProvider

Type Parameters

TProviderServices The base set of services required by EF for the database provider to function.
TOptionsExtension The type of options that the database provider will add to Extensions to identify that is has been selected (and to store its database specific settings).

Inheritance Hierarchy

  • System.Object
    System.Object
  • DatabaseProvider<TProviderServices, TOptionsExtension>
    DatabaseProvider(Of TProviderServices, TOptionsExtension)

Inherited Members

ToString(),
ToString(),
Equals(Object),
Equals(Object),
Equals(Object, Object),
Equals(Object, Object),
ReferenceEquals(Object, Object),
ReferenceEquals(Object, Object),
GetHashCode(),
GetHashCode(),
GetType(),
GetType(),
MemberwiseClone()
MemberwiseClone()

Methods summary

Gets the base set of services required by EF for the database provider to function.

Gets a value indicating whether this database provider has been selected for a given context.

Methods

  • GetProviderServices(IServiceProvider)
    GetProviderServices(IServiceProvider)

    Gets the base set of services required by EF for the database provider to function.

    public virtual IDatabaseProviderServices GetProviderServices(IServiceProvider serviceProvider)Public Overridable Function GetProviderServices(serviceProvider As IServiceProvider) As IDatabaseProviderServices

    Parameters

    • serviceProvider
      System.IServiceProvider
      System.IServiceProvider

      The service provider to resolve services from.

    Returns

  • IsConfigured(IDbContextOptions)
    IsConfigured(IDbContextOptions)

    Gets a value indicating whether this database provider has been selected for a given context.

    public virtual bool IsConfigured(IDbContextOptions options)Public Overridable Function IsConfigured(options As IDbContextOptions) As Boolean

    Parameters

    Returns

    • System.Boolean
      System.Boolean

      True if the database provider has been selected, otherwise false.

Details

Assembly

Microsoft.EntityFrameworkCore.dll