RewriteMiddleware 构造函数
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
重载
RewriteMiddleware(RequestDelegate, IHostingEnvironment, ILoggerFactory, RewriteOptions)
创建 RewriteMiddleware 的新实例
public:
RewriteMiddleware(Microsoft::AspNetCore::Http::RequestDelegate ^ next, Microsoft::AspNetCore::Hosting::IHostingEnvironment ^ hostingEnvironment, Microsoft::Extensions::Logging::ILoggerFactory ^ loggerFactory, Microsoft::AspNetCore::Rewrite::RewriteOptions ^ options);
public RewriteMiddleware (Microsoft.AspNetCore.Http.RequestDelegate next, Microsoft.AspNetCore.Hosting.IHostingEnvironment hostingEnvironment, Microsoft.Extensions.Logging.ILoggerFactory loggerFactory, Microsoft.AspNetCore.Rewrite.RewriteOptions options);
new Microsoft.AspNetCore.Rewrite.RewriteMiddleware : Microsoft.AspNetCore.Http.RequestDelegate * Microsoft.AspNetCore.Hosting.IHostingEnvironment * Microsoft.Extensions.Logging.ILoggerFactory * Microsoft.AspNetCore.Rewrite.RewriteOptions -> Microsoft.AspNetCore.Rewrite.RewriteMiddleware
Public Sub New (next As RequestDelegate, hostingEnvironment As IHostingEnvironment, loggerFactory As ILoggerFactory, options As RewriteOptions)
参数
- next
- RequestDelegate
表示请求管道中下一个中间件的委托。
- hostingEnvironment
- IHostingEnvironment
宿主环境。
- loggerFactory
- ILoggerFactory
记录器工厂。
- options
- RewriteOptions
中间件选项,包含要应用的规则。
适用于
RewriteMiddleware(RequestDelegate, IHostingEnvironment, ILoggerFactory, IOptions<RewriteOptions>)
- Source:
- RewriteMiddleware.cs
- Source:
- RewriteMiddleware.cs
创建 RewriteMiddleware 的新实例
public:
RewriteMiddleware(Microsoft::AspNetCore::Http::RequestDelegate ^ next, Microsoft::AspNetCore::Hosting::IHostingEnvironment ^ hostingEnvironment, Microsoft::Extensions::Logging::ILoggerFactory ^ loggerFactory, Microsoft::Extensions::Options::IOptions<Microsoft::AspNetCore::Rewrite::RewriteOptions ^> ^ options);
public RewriteMiddleware (Microsoft.AspNetCore.Http.RequestDelegate next, Microsoft.AspNetCore.Hosting.IHostingEnvironment hostingEnvironment, Microsoft.Extensions.Logging.ILoggerFactory loggerFactory, Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Rewrite.RewriteOptions> options);
new Microsoft.AspNetCore.Rewrite.RewriteMiddleware : Microsoft.AspNetCore.Http.RequestDelegate * Microsoft.AspNetCore.Hosting.IHostingEnvironment * Microsoft.Extensions.Logging.ILoggerFactory * Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Rewrite.RewriteOptions> -> Microsoft.AspNetCore.Rewrite.RewriteMiddleware
Public Sub New (next As RequestDelegate, hostingEnvironment As IHostingEnvironment, loggerFactory As ILoggerFactory, options As IOptions(Of RewriteOptions))
参数
- next
- RequestDelegate
表示请求管道中下一个中间件的委托。
- hostingEnvironment
- IHostingEnvironment
宿主环境。
- loggerFactory
- ILoggerFactory
记录器工厂。
- options
- IOptions<RewriteOptions>
中间件选项,包含要应用的规则。
适用于
RewriteMiddleware(RequestDelegate, IWebHostEnvironment, ILoggerFactory, IOptions<RewriteOptions>)
- Source:
- RewriteMiddleware.cs
创建 RewriteMiddleware 的新实例
public:
RewriteMiddleware(Microsoft::AspNetCore::Http::RequestDelegate ^ next, Microsoft::AspNetCore::Hosting::IWebHostEnvironment ^ hostingEnvironment, Microsoft::Extensions::Logging::ILoggerFactory ^ loggerFactory, Microsoft::Extensions::Options::IOptions<Microsoft::AspNetCore::Rewrite::RewriteOptions ^> ^ options);
public RewriteMiddleware (Microsoft.AspNetCore.Http.RequestDelegate next, Microsoft.AspNetCore.Hosting.IWebHostEnvironment hostingEnvironment, Microsoft.Extensions.Logging.ILoggerFactory loggerFactory, Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Rewrite.RewriteOptions> options);
new Microsoft.AspNetCore.Rewrite.RewriteMiddleware : Microsoft.AspNetCore.Http.RequestDelegate * Microsoft.AspNetCore.Hosting.IWebHostEnvironment * Microsoft.Extensions.Logging.ILoggerFactory * Microsoft.Extensions.Options.IOptions<Microsoft.AspNetCore.Rewrite.RewriteOptions> -> Microsoft.AspNetCore.Rewrite.RewriteMiddleware
Public Sub New (next As RequestDelegate, hostingEnvironment As IWebHostEnvironment, loggerFactory As ILoggerFactory, options As IOptions(Of RewriteOptions))
参数
- next
- RequestDelegate
表示请求管道中下一个中间件的委托。
- hostingEnvironment
- IWebHostEnvironment
宿主环境。
- loggerFactory
- ILoggerFactory
记录器工厂。
- options
- IOptions<RewriteOptions>
中间件选项,包含要应用的规则。