HttpContextFactory 建構函式
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
多載
HttpContextFactory(IOptions<FormOptions>) |
使用傳入的選項,初始化 HttpCoNtext 類別的新實例。 |
HttpContextFactory(ObjectPoolProvider, IOptions<FormOptions>) | |
HttpContextFactory(IOptions<FormOptions>, IHttpContextAccessor) |
使用傳入的選項,初始化 DefaultHttpCoNtext 類別的新實例。 |
HttpContextFactory(IOptions<FormOptions>, IServiceScopeFactory) |
使用傳入的選項,初始化 DefaultHttpCoNtext 類別的新實例。 |
HttpContextFactory(ObjectPoolProvider, IOptions<FormOptions>, IHttpContextAccessor) | |
HttpContextFactory(IOptions<FormOptions>, IServiceScopeFactory, IHttpContextAccessor) |
使用傳入的選項,初始化 DefaultHttpCoNtext 類別的新實例。 |
HttpContextFactory(IOptions<FormOptions>)
使用傳入的選項,初始化 HttpCoNtext 類別的新實例。
public:
HttpContextFactory(Microsoft::Extensions::Options::IOptions<Microsoft::AspNetCore::Http::Features::FormOptions ^> ^ formOptions);
public HttpContextFactory (Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Http.Features.FormOptions> formOptions);
new Microsoft.AspNetCore.Http.HttpContextFactory : Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Http.Features.FormOptions> -> Microsoft.AspNetCore.Http.HttpContextFactory
Public Sub New (formOptions As IOptions(Of FormOptions))
參數
- formOptions
- IOptions<FormOptions>
具現化 HTTP 內容物件時要設定的選項。
適用於
HttpContextFactory(ObjectPoolProvider, IOptions<FormOptions>)
public:
HttpContextFactory(Microsoft::Extensions::ObjectPool::ObjectPoolProvider ^ poolProvider, Microsoft::Extensions::Options::IOptions<Microsoft::AspNetCore::Http::Features::FormOptions ^> ^ formOptions);
public HttpContextFactory (Microsoft.Extensions.ObjectPool.ObjectPoolProvider poolProvider, Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Http.Features.FormOptions> formOptions);
new Microsoft.AspNetCore.Http.HttpContextFactory : Microsoft.Extensions.ObjectPool.ObjectPoolProvider * Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Http.Features.FormOptions> -> Microsoft.AspNetCore.Http.HttpContextFactory
Public Sub New (poolProvider As ObjectPoolProvider, formOptions As IOptions(Of FormOptions))
參數
- poolProvider
- ObjectPoolProvider
- formOptions
- IOptions<FormOptions>
適用於
HttpContextFactory(IOptions<FormOptions>, IHttpContextAccessor)
使用傳入的選項,初始化 DefaultHttpCoNtext 類別的新實例。
public:
HttpContextFactory(Microsoft::Extensions::Options::IOptions<Microsoft::AspNetCore::Http::Features::FormOptions ^> ^ formOptions, Microsoft::AspNetCore::Http::IHttpContextAccessor ^ httpContextAccessor);
public HttpContextFactory (Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Http.Features.FormOptions> formOptions, Microsoft.AspNetCore.Http.IHttpContextAccessor httpContextAccessor);
public HttpContextFactory (Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Http.Features.FormOptions> formOptions, Microsoft.AspNetCore.Http.IHttpContextAccessor? httpContextAccessor);
new Microsoft.AspNetCore.Http.HttpContextFactory : Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Http.Features.FormOptions> * Microsoft.AspNetCore.Http.IHttpContextAccessor -> Microsoft.AspNetCore.Http.HttpContextFactory
Public Sub New (formOptions As IOptions(Of FormOptions), httpContextAccessor As IHttpContextAccessor)
參數
- formOptions
- IOptions<FormOptions>
具現化 HTTP 內容物件時要設定的選項。
- httpContextAccessor
- IHttpContextAccessor
要用來存取 HTTP 內容實例的物件。
適用於
HttpContextFactory(IOptions<FormOptions>, IServiceScopeFactory)
使用傳入的選項,初始化 DefaultHttpCoNtext 類別的新實例。
public:
HttpContextFactory(Microsoft::Extensions::Options::IOptions<Microsoft::AspNetCore::Http::Features::FormOptions ^> ^ formOptions, Microsoft::Extensions::DependencyInjection::IServiceScopeFactory ^ serviceScopeFactory);
public HttpContextFactory (Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Http.Features.FormOptions> formOptions, Microsoft.Extensions.DependencyInjection.IServiceScopeFactory serviceScopeFactory);
new Microsoft.AspNetCore.Http.HttpContextFactory : Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Http.Features.FormOptions> * Microsoft.Extensions.DependencyInjection.IServiceScopeFactory -> Microsoft.AspNetCore.Http.HttpContextFactory
Public Sub New (formOptions As IOptions(Of FormOptions), serviceScopeFactory As IServiceScopeFactory)
參數
- formOptions
- IOptions<FormOptions>
具現化 HTTP 內容物件時要設定的選項。
- serviceScopeFactory
- IServiceScopeFactory
用來建立 HTTP 內容之服務範圍的 Factory 物件。
適用於
HttpContextFactory(ObjectPoolProvider, IOptions<FormOptions>, IHttpContextAccessor)
public:
HttpContextFactory(Microsoft::Extensions::ObjectPool::ObjectPoolProvider ^ poolProvider, Microsoft::Extensions::Options::IOptions<Microsoft::AspNetCore::Http::Features::FormOptions ^> ^ formOptions, Microsoft::AspNetCore::Http::IHttpContextAccessor ^ httpContextAccessor);
public HttpContextFactory (Microsoft.Extensions.ObjectPool.ObjectPoolProvider poolProvider, Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Http.Features.FormOptions> formOptions, Microsoft.AspNetCore.Http.IHttpContextAccessor httpContextAccessor);
new Microsoft.AspNetCore.Http.HttpContextFactory : Microsoft.Extensions.ObjectPool.ObjectPoolProvider * Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Http.Features.FormOptions> * Microsoft.AspNetCore.Http.IHttpContextAccessor -> Microsoft.AspNetCore.Http.HttpContextFactory
Public Sub New (poolProvider As ObjectPoolProvider, formOptions As IOptions(Of FormOptions), httpContextAccessor As IHttpContextAccessor)
參數
- poolProvider
- ObjectPoolProvider
- formOptions
- IOptions<FormOptions>
- httpContextAccessor
- IHttpContextAccessor
適用於
HttpContextFactory(IOptions<FormOptions>, IServiceScopeFactory, IHttpContextAccessor)
使用傳入的選項,初始化 DefaultHttpCoNtext 類別的新實例。
public:
HttpContextFactory(Microsoft::Extensions::Options::IOptions<Microsoft::AspNetCore::Http::Features::FormOptions ^> ^ formOptions, Microsoft::Extensions::DependencyInjection::IServiceScopeFactory ^ serviceScopeFactory, Microsoft::AspNetCore::Http::IHttpContextAccessor ^ httpContextAccessor);
public HttpContextFactory (Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Http.Features.FormOptions> formOptions, Microsoft.Extensions.DependencyInjection.IServiceScopeFactory serviceScopeFactory, Microsoft.AspNetCore.Http.IHttpContextAccessor httpContextAccessor);
public HttpContextFactory (Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Http.Features.FormOptions> formOptions, Microsoft.Extensions.DependencyInjection.IServiceScopeFactory serviceScopeFactory, Microsoft.AspNetCore.Http.IHttpContextAccessor? httpContextAccessor);
new Microsoft.AspNetCore.Http.HttpContextFactory : Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Http.Features.FormOptions> * Microsoft.Extensions.DependencyInjection.IServiceScopeFactory * Microsoft.AspNetCore.Http.IHttpContextAccessor -> Microsoft.AspNetCore.Http.HttpContextFactory
Public Sub New (formOptions As IOptions(Of FormOptions), serviceScopeFactory As IServiceScopeFactory, httpContextAccessor As IHttpContextAccessor)
參數
- formOptions
- IOptions<FormOptions>
具現化 HTTP 內容物件時要設定的選項。
- serviceScopeFactory
- IServiceScopeFactory
用來建立 HTTP 內容之服務範圍的 Factory 物件。
- httpContextAccessor
- IHttpContextAccessor
具現化預設 HTTP 內容物件時要設定的選項。