private static void RegisterLogger(IComponentContext context, PostgreSQLOptions options) { ILogger logger = null; if (context.TryResolve <ILogger>(out logger)) { NpgsqlLogManager.IsParameterLoggingEnabled = true; NpgsqlLogManager.Provider = new PostgreSQLLoggingProvider(logger, options.LogLevel); } loggerRegistered = true; }
public NpgSQLData(PostgreSQLOptions postgreSQLOptions) { this.postgreSQLOptions = postgreSQLOptions; npgsqlConnection = new NpgsqlConnection(this.postgreSQLOptions.ConnectionString); npgsqlConnection.Open(); }
public PostgreSQLBootstrap(PostgreSQLOptions postgreSQLOptions) { this.postgreSQLOptions = postgreSQLOptions; }