共用方式為


StaticFileMiddleware 建構函式

定義

多載

StaticFileMiddleware(RequestDelegate, IHostingEnvironment, IOptions<StaticFileOptions>, ILoggerFactory)

建立 StaticFileMiddleware 的新執行個體。

StaticFileMiddleware(RequestDelegate, IWebHostEnvironment, IOptions<StaticFileOptions>, ILoggerFactory)

建立 StaticFileMiddleware 的新執行個體。

StaticFileMiddleware(RequestDelegate, IHostingEnvironment, IOptions<StaticFileOptions>, ILoggerFactory)

來源:
StaticFileMiddleware.cs
來源:
StaticFileMiddleware.cs

建立 StaticFileMiddleware 的新執行個體。

public:
 StaticFileMiddleware(Microsoft::AspNetCore::Http::RequestDelegate ^ next, Microsoft::AspNetCore::Hosting::IHostingEnvironment ^ hostingEnv, Microsoft::Extensions::Options::IOptions<Microsoft::AspNetCore::Builder::StaticFileOptions ^> ^ options, Microsoft::Extensions::Logging::ILoggerFactory ^ loggerFactory);
public StaticFileMiddleware (Microsoft.AspNetCore.Http.RequestDelegate next, Microsoft.AspNetCore.Hosting.IHostingEnvironment hostingEnv, Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Builder.StaticFileOptions> options, Microsoft.Extensions.Logging.ILoggerFactory loggerFactory);
new Microsoft.AspNetCore.StaticFiles.StaticFileMiddleware : Microsoft.AspNetCore.Http.RequestDelegate * Microsoft.AspNetCore.Hosting.IHostingEnvironment * Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Builder.StaticFileOptions> * Microsoft.Extensions.Logging.ILoggerFactory -> Microsoft.AspNetCore.StaticFiles.StaticFileMiddleware
Public Sub New (next As RequestDelegate, hostingEnv As IHostingEnvironment, options As IOptions(Of StaticFileOptions), loggerFactory As ILoggerFactory)

參數

next
RequestDelegate

管線中的下一個中介軟體。

hostingEnv
IHostingEnvironment

IHostingEnvironment這個中介軟體所使用的 。

options
IOptions<StaticFileOptions>

組態選項。

loggerFactory
ILoggerFactory

ILoggerFactory用來建立記錄器的實例。

適用於

StaticFileMiddleware(RequestDelegate, IWebHostEnvironment, IOptions<StaticFileOptions>, ILoggerFactory)

來源:
StaticFileMiddleware.cs

建立 StaticFileMiddleware 的新執行個體。

public:
 StaticFileMiddleware(Microsoft::AspNetCore::Http::RequestDelegate ^ next, Microsoft::AspNetCore::Hosting::IWebHostEnvironment ^ hostingEnv, Microsoft::Extensions::Options::IOptions<Microsoft::AspNetCore::Builder::StaticFileOptions ^> ^ options, Microsoft::Extensions::Logging::ILoggerFactory ^ loggerFactory);
public StaticFileMiddleware (Microsoft.AspNetCore.Http.RequestDelegate next, Microsoft.AspNetCore.Hosting.IWebHostEnvironment hostingEnv, Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Builder.StaticFileOptions> options, Microsoft.Extensions.Logging.ILoggerFactory loggerFactory);
new Microsoft.AspNetCore.StaticFiles.StaticFileMiddleware : Microsoft.AspNetCore.Http.RequestDelegate * Microsoft.AspNetCore.Hosting.IWebHostEnvironment * Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Builder.StaticFileOptions> * Microsoft.Extensions.Logging.ILoggerFactory -> Microsoft.AspNetCore.StaticFiles.StaticFileMiddleware
Public Sub New (next As RequestDelegate, hostingEnv As IWebHostEnvironment, options As IOptions(Of StaticFileOptions), loggerFactory As ILoggerFactory)

參數

next
RequestDelegate

管線中的下一個中介軟體。

hostingEnv
IWebHostEnvironment

IWebHostEnvironment這個中介軟體所使用的 。

options
IOptions<StaticFileOptions>

組態選項。

loggerFactory
ILoggerFactory

ILoggerFactory用來建立記錄器的實例。

適用於