Table of Contents

Class PostgreSqlDbContextOptionsBuilderExtensions

Namespace
Steeltoe.Connectors.EntityFrameworkCore.PostgreSql
Assembly
Steeltoe.Connectors.EntityFrameworkCore.dll
public static class PostgreSqlDbContextOptionsBuilderExtensions
Inheritance
PostgreSqlDbContextOptionsBuilderExtensions
Inherited Members

Methods

UseNpgsql(DbContextOptionsBuilder, IServiceProvider)

Configures the context to connect to a PostgreSQL server with Npgsql, using the default service binding.

public static DbContextOptionsBuilder UseNpgsql(this DbContextOptionsBuilder builder, IServiceProvider serviceProvider)

Parameters

builder DbContextOptionsBuilder

The builder being used to configure the DbContext.

serviceProvider IServiceProvider

The application's configured services.

Returns

DbContextOptionsBuilder

The incoming builder so that additional calls can be chained.

UseNpgsql(DbContextOptionsBuilder, IServiceProvider, string?)

Configures the context to connect to a PostgreSQL server with Npgsql, using a named service binding.

public static DbContextOptionsBuilder UseNpgsql(this DbContextOptionsBuilder builder, IServiceProvider serviceProvider, string? serviceBindingName)

Parameters

builder DbContextOptionsBuilder

The builder being used to configure the DbContext.

serviceProvider IServiceProvider

The application's configured services.

serviceBindingName string

The service binding name, or null to use the default service binding.

Returns

DbContextOptionsBuilder

The incoming builder so that additional calls can be chained.

UseNpgsql(DbContextOptionsBuilder, IServiceProvider, string?, Action<object>?)

Configures the context to connect to a PostgreSQL server with Npgsql, using a named service binding and options.

public static DbContextOptionsBuilder UseNpgsql(this DbContextOptionsBuilder builder, IServiceProvider serviceProvider, string? serviceBindingName, Action<object>? npgsqlOptionsAction)

Parameters

builder DbContextOptionsBuilder

The builder being used to configure the DbContext.

serviceProvider IServiceProvider

The application's configured services.

serviceBindingName string

The service binding name, or null to use the default service binding.

npgsqlOptionsAction Action<object>

An action to allow additional Npgsql-specific configuration.

Returns

DbContextOptionsBuilder

The incoming builder so that additional calls can be chained.