# Interface INpgsqlDatabaseInfoFactory

Namespace
  Npgsql.Internal

Assembly
  Npgsql.dll

A factory which get generate instances of NpgsqlDatabaseInfo, which describe a database and the types it contains. When first connecting to a database, Npgsql will attempt to load information about it via this factory.

    public interface INpgsqlDatabaseInfoFactory

## Methods

### Load(NpgsqlConnector, NpgsqlTimeout, bool)

Given a connection, loads all necessary information about the connected database, e.g. its types. A factory should only handle the exact database type it was meant for, and return null otherwise.

    Task<NpgsqlDatabaseInfo?> Load(NpgsqlConnector conn, NpgsqlTimeout timeout, bool async)

#### Parameters

`conn` NpgsqlConnector
`timeout` NpgsqlTimeout
`async` bool

#### Returns

Task<NpgsqlDatabaseInfo>

  An object describing the database to which `conn` is connected, or null if the database isn't of the correct type and isn't handled by this factory.