Documentation
Table of Contents

Class AdoSchemaDiscovery

Namespace
IntentSharp.Data
Assembly
IntentSharp.dll

Discovery that works across common ADO.NET providers: SQLite through sqlite_master and PRAGMA table_info; SQL Server, PostgreSQL and MySQL through INFORMATION_SCHEMA; anything else through GetSchema(string). The connection string is never copied into the result.

public sealed class AdoSchemaDiscovery : ISchemaDiscovery
Inheritance
object
AdoSchemaDiscovery
Implements
Inherited Members
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.ReferenceEquals(object, object)
object.ToString()
Extension Methods

Constructors

AdoSchemaDiscovery()

Creates a discovery. It holds no state, so one instance can serve every connection.

Methods

DetectDialect(DbConnection)

The dialect named by the connection's type: the first of Sqlite, MySql, SqlClient, Npgsql and Oracle that the full type name contains, else "SQL". MySql is tested before SqlClient because the MySql.Data connection is MySql.Data.MySqlClient.MySqlConnection.

DiscoverAsync(DbConnection, CancellationToken)

Reads the tables, views and columns that connection can see. A closed connection is opened for the discovery and closed again; an open one is left open.