IdentityDbContext Constructor

 

Initializes a new instance of the IdentityDbContext class.

Namespace:   Microsoft.AspNet.Identity.EntityFramework
Assembly:  Microsoft.AspNet.Identity.EntityFramework (in Microsoft.AspNet.Identity.EntityFramework.dll)

Overload List

Name Description
System_CAPS_pubmethod IdentityDbContext()

Initializes a new instance of the IdentityDbContext class.

System_CAPS_pubmethod IdentityDbContext(DbConnection, DbCompiledModel, Boolean)

Initializes a new instance of the IdentityDbContext class using the existing connection to connect to a database, and initializes it from the given model. The connection will not be disposed when the context is disposed if contextOwnsConnection is false.

System_CAPS_pubmethod IdentityDbContext(String)

Initializes a new instance of the IdentityDbContext class which takes the connection string to use.

See Also

IdentityDbContext Class
Microsoft.AspNet.Identity.EntityFramework Namespace
ASP.NET Identity

Return to top

IdentityDbContext Constructor ()

Initializes a new instance of the IdentityDbContext class.

Syntax

public IdentityDbContext()
public:
IdentityDbContext()
new : unit -> IdentityDbContext
Public Sub New

See Also

ASP.NET Identity

Return to top

IdentityDbContext Constructor (DbConnection, DbCompiledModel, Boolean)

Initializes a new instance of the IdentityDbContext class using the existing connection to connect to a database, and initializes it from the given model. The connection will not be disposed when the context is disposed if contextOwnsConnection is false.

Syntax

public IdentityDbContext(
    DbConnection existingConnection,
    DbCompiledModel model,
    bool contextOwnsConnection
)
public:
IdentityDbContext(
    DbConnection^ existingConnection,
    DbCompiledModel^ model,
    bool contextOwnsConnection
)
new : 
        existingConnection:DbConnection *
        model:DbCompiledModel *
        contextOwnsConnection:bool -> IdentityDbContext
Public Sub New (
    existingConnection As DbConnection,
    model As DbCompiledModel,
    contextOwnsConnection As Boolean
)

Parameters

  • contextOwnsConnection
    Type: System.Boolean

    Determines whether the context instance owns a connection. The connection will not be disposed when the context is disposed when this parameter is false.

See Also

ASP.NET Identity

Return to top

IdentityDbContext Constructor (String)

Initializes a new instance of the IdentityDbContext class which takes the connection string to use.

Syntax

public IdentityDbContext(
    string nameOrConnectionString
)
public:
IdentityDbContext(
    String^ nameOrConnectionString
)
new : 
        nameOrConnectionString:string -> IdentityDbContext
Public Sub New (
    nameOrConnectionString As String
)

Parameters

  • nameOrConnectionString
    Type: System.String

    The connection string.

See Also

ASP.NET Identity

Return to top