AddKeyedOracleCollection<TKey, TRecord>(IServiceCollection, object?, string, Func<IServiceProvider, string>, Func<IServiceProvider, OracleVectorCollectionOptions>?, ServiceLifetime )
このメソッドは、指定された接続文字列プロバイダおよびサービス存続期間を使用して、キーが指定されたOracleCollection<TKey, TRecord>を、VectorStoreCollectionとして登録します。
宣言
// C#
public static IServiceCollection AddKeyedOracleCollection<TKey, TRecord>(this IServiceCollection services, object? serviceKey, string name, Func<IServiceProvider, string> connectionStringProvider, Func<IServiceProvider, OracleVectorCollectionOptions>? optionsProvider = null, ServiceLifetime lifetime = ServiceLifeTime.Singleton) where TKey : notnull where TRecord : classパラメータ
TKeyOracleCollection<TKey, TRecord>のキー・タイプ。TRecordOracleCollection<TKey, TRecord>のレコード・タイプ。servicesVectorStoreを登録するIServiceCollection。serviceKeyベクトル・コレクションに関連付けるキー。
nameコレクションの名前。
connectionStringProvider接続文字列プロバイダ。
optionsProviderベクトル・ストアを詳細に構成するための省略可能なオプション・プロバイダ。
lifetimeストアのサービス存続期間。デフォルトは
ServiceLifetime.Singletonです。
戻り値
サービス・コレクションを返します。
例外
InvalidArgumentException:
- 指定された
connectionStringProviderまたはservicesパラメータがnullです。 - 指定された
nameパラメータがnullまたは空です。