Table of Contents

Class SqliteConnectionFactory

Namespace
Fdyay.IdentityServer.Dapper.Sql
Assembly
Fdyay.IdentityServer.Dapper.dll

Opens SQLite connections.

public sealed class SqliteConnectionFactory : IDbConnectionFactory
Inheritance
SqliteConnectionFactory
Implements
Inherited Members

Constructors

SqliteConnectionFactory(string)

Creates a factory that opens connections with connectionString.

public SqliteConnectionFactory(string connectionString)

Parameters

connectionString string

The SQLite connection string. Held as given; nothing connects until OpenConnectionAsync(CancellationToken) is called.

Exceptions

ArgumentException

connectionString is null or empty.

Properties

Dialect

The SQL dialect for the configured provider.

public ISqlDialect Dialect { get; }

Property Value

ISqlDialect

Remarks

Always a SqliteDialect.

Methods

OpenConnectionAsync(CancellationToken)

Opens a new connection.

public Task<DbConnection> OpenConnectionAsync(CancellationToken cancellationToken = default)

Parameters

cancellationToken CancellationToken

Returns

Task<DbConnection>

Remarks

A new SqliteConnection per call, already open; the caller disposes it.