InMemoryDbContextOptionsExtensions InMemoryDbContextOptionsExtensions Class

In-memory specific extension methods for DbContextOptionsBuilder.

Syntax

Declaration

public static class InMemoryDbContextOptionsExtensionsPublic Module InMemoryDbContextOptionsExtensions

Inheritance Hierarchy

  • System.Object
    System.Object
  • InMemoryDbContextOptionsExtensions
    InMemoryDbContextOptionsExtensions

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

Configures the context to connect to an in-memory database. By default, the same in-memory database instance will be shared by all instances of a given context type. To change this, use the overload that takes a database name.

Configures the context to connect to an in-memory database.

Configures the context to connect to an in-memory database. By default, the same in-memory database instance will be shared by all instances of a given context type. To change this, use the overload that takes a database name.

Configures the context to connect to an in-memory database.

Methods

  • UseInMemoryDatabase(DbContextOptionsBuilder, Action<InMemoryDbContextOptionsBuilder>)
    UseInMemoryDatabase(DbContextOptionsBuilder, Action(Of InMemoryDbContextOptionsBuilder))

    Configures the context to connect to an in-memory database. By default, the same in-memory database instance will be shared by all instances of a given context type. To change this, use the overload that takes a database name.

    public static DbContextOptionsBuilder UseInMemoryDatabase(this DbContextOptionsBuilder optionsBuilder, Action<InMemoryDbContextOptionsBuilder> inMemoryOptionsAction = null)<ExtensionAttribute>
    Public Shared Function UseInMemoryDatabase(optionsBuilder As DbContextOptionsBuilder, inMemoryOptionsAction As Action(Of InMemoryDbContextOptionsBuilder) = Nothing) As DbContextOptionsBuilder

    Parameters

    Returns

  • UseInMemoryDatabase(DbContextOptionsBuilder, String, Action<InMemoryDbContextOptionsBuilder>)
    UseInMemoryDatabase(DbContextOptionsBuilder, String, Action(Of InMemoryDbContextOptionsBuilder))

    Configures the context to connect to an in-memory database.

    public static DbContextOptionsBuilder UseInMemoryDatabase(this DbContextOptionsBuilder optionsBuilder, string databaseName, Action<InMemoryDbContextOptionsBuilder> inMemoryOptionsAction = null)<ExtensionAttribute>
    Public Shared Function UseInMemoryDatabase(optionsBuilder As DbContextOptionsBuilder, databaseName As String, inMemoryOptionsAction As Action(Of InMemoryDbContextOptionsBuilder) = Nothing) As DbContextOptionsBuilder

    Parameters

    Returns

  • UseInMemoryDatabase<TContext>(DbContextOptionsBuilder<TContext>, Action<InMemoryDbContextOptionsBuilder>)
    UseInMemoryDatabase(Of TContext)(DbContextOptionsBuilder(Of TContext), Action(Of InMemoryDbContextOptionsBuilder))

    Configures the context to connect to an in-memory database. By default, the same in-memory database instance will be shared by all instances of a given context type. To change this, use the overload that takes a database name.

    public static DbContextOptionsBuilder<TContext> UseInMemoryDatabase<TContext>(this DbContextOptionsBuilder<TContext> optionsBuilder, Action<InMemoryDbContextOptionsBuilder> inMemoryOptionsAction = null)where TContext : DbContext<ExtensionAttribute>
    Public Shared Function UseInMemoryDatabase(Of TContext As DbContext)(optionsBuilder As DbContextOptionsBuilder(Of TContext), inMemoryOptionsAction As Action(Of InMemoryDbContextOptionsBuilder) = Nothing) As DbContextOptionsBuilder(Of TContext)

    Parameters

    Returns

  • UseInMemoryDatabase<TContext>(DbContextOptionsBuilder<TContext>, String, Action<InMemoryDbContextOptionsBuilder>)
    UseInMemoryDatabase(Of TContext)(DbContextOptionsBuilder(Of TContext), String, Action(Of InMemoryDbContextOptionsBuilder))

    Configures the context to connect to an in-memory database.

    public static DbContextOptionsBuilder<TContext> UseInMemoryDatabase<TContext>(this DbContextOptionsBuilder<TContext> optionsBuilder, string databaseName, Action<InMemoryDbContextOptionsBuilder> inMemoryOptionsAction = null)where TContext : DbContext<ExtensionAttribute>
    Public Shared Function UseInMemoryDatabase(Of TContext As DbContext)(optionsBuilder As DbContextOptionsBuilder(Of TContext), databaseName As String, inMemoryOptionsAction As Action(Of InMemoryDbContextOptionsBuilder) = Nothing) As DbContextOptionsBuilder(Of TContext)

    Parameters

    Returns

Details

Assembly

Microsoft.EntityFrameworkCore.InMemory.dll