Table of Contents

Class RelationalOptionsExtension.RelationalExtensionInfo

Namespace
Microsoft.EntityFrameworkCore.Infrastructure
Assembly
Microsoft.EntityFrameworkCore.Relational.dll

Information/metadata for a RelationalOptionsExtension.

protected abstract class RelationalOptionsExtension.RelationalExtensionInfo : DbContextOptionsExtensionInfo
Inheritance
RelationalOptionsExtension.RelationalExtensionInfo

Constructors

RelationalExtensionInfo(IDbContextOptionsExtension)

Creates a new RelationalOptionsExtension.RelationalExtensionInfo instance containing info/metadata for the given extension.

protected RelationalExtensionInfo(IDbContextOptionsExtension extension)

Parameters

extension IDbContextOptionsExtension

The extension.

Properties

Extension

The extension for which this instance contains metadata.

public virtual RelationalOptionsExtension Extension { get; }

Property Value

RelationalOptionsExtension

IsDatabaseProvider

True, since this is a database provider base class.

public override bool IsDatabaseProvider { get; }

Property Value

bool

LogFragment

A message fragment for logging typically containing information about any useful non-default options that have been configured.

public override string LogFragment { get; }

Property Value

string

Methods

GetServiceProviderHashCode()

Returns a hash code created from any options that would cause a new IServiceProvider to be needed. For example, if the options affect a singleton service. However most extensions do not have any such options and should return zero.

public override int GetServiceProviderHashCode()

Returns

int

A hash over options that require a new service provider when changed.

ShouldUseSameServiceProvider(DbContextOptionsExtensionInfo)

Returns a value indicating whether all of the options used in GetServiceProviderHashCode() are the same as in the given extension.

public override bool ShouldUseSameServiceProvider(DbContextOptionsExtensionInfo other)

Parameters

other DbContextOptionsExtensionInfo

The other extension.

Returns

bool

A value indicating whether all of the options that require a new service provider are the same.