共用方式為


RazorPagesEndpointRouteBuilderExtensions.MapDynamicPageRoute 方法

定義

多載

MapDynamicPageRoute<TTransformer>(IEndpointRouteBuilder, String)

將特製化 RouteEndpoint 新增至 IEndpointRouteBuilder ,其會嘗試使用 所產生的 TTransformer 路由值來選取頁面。

MapDynamicPageRoute<TTransformer>(IEndpointRouteBuilder, String, Object)

將特製化 RouteEndpoint 新增至 IEndpointRouteBuilder ,其會嘗試使用 所產生的 TTransformer 路由值來選取頁面。

MapDynamicPageRoute<TTransformer>(IEndpointRouteBuilder, String, Object, Int32)

將特製化 RouteEndpoint 新增至 IEndpointRouteBuilder ,其會嘗試使用 所產生的 TTransformer 路由值來選取頁面。

MapDynamicPageRoute<TTransformer>(IEndpointRouteBuilder, String)

來源:
RazorPagesEndpointRouteBuilderExtensions.cs

將特製化 RouteEndpoint 新增至 IEndpointRouteBuilder ,其會嘗試使用 所產生的 TTransformer 路由值來選取頁面。

public:
generic <typename TTransformer>
 where TTransformer : Microsoft::AspNetCore::Mvc::Routing::DynamicRouteValueTransformer[System::Runtime::CompilerServices::Extension]
 static void MapDynamicPageRoute(Microsoft::AspNetCore::Routing::IEndpointRouteBuilder ^ endpoints, System::String ^ pattern);
public static void MapDynamicPageRoute<TTransformer> (this Microsoft.AspNetCore.Routing.IEndpointRouteBuilder endpoints, string pattern) where TTransformer : Microsoft.AspNetCore.Mvc.Routing.DynamicRouteValueTransformer;
static member MapDynamicPageRoute : Microsoft.AspNetCore.Routing.IEndpointRouteBuilder * string -> unit (requires 'ransformer :> Microsoft.AspNetCore.Mvc.Routing.DynamicRouteValueTransformer)
<Extension()>
Public Sub MapDynamicPageRoute(Of TTransformer As DynamicRouteValueTransformer) (endpoints As IEndpointRouteBuilder, pattern As String)

類型參數

TTransformer

的型別 DynamicRouteValueTransformer

參數

endpoints
IEndpointRouteBuilder

IEndpointRouteBuilder要加入路由的 。

pattern
String

路由的 URL 模式。

備註

這個方法允許註冊 RouteEndpoint ,並 DynamicRouteValueTransformer 結合以動態方式使用自訂邏輯來選取頁面。

的實例 TTransformer 將會從相依性插入容器擷取。 在 中 ConfigureServices 向所需的服務存留期註冊 TTransformer

適用於

MapDynamicPageRoute<TTransformer>(IEndpointRouteBuilder, String, Object)

來源:
RazorPagesEndpointRouteBuilderExtensions.cs

將特製化 RouteEndpoint 新增至 IEndpointRouteBuilder ,其會嘗試使用 所產生的 TTransformer 路由值來選取頁面。

public:
generic <typename TTransformer>
 where TTransformer : Microsoft::AspNetCore::Mvc::Routing::DynamicRouteValueTransformer[System::Runtime::CompilerServices::Extension]
 static void MapDynamicPageRoute(Microsoft::AspNetCore::Routing::IEndpointRouteBuilder ^ endpoints, System::String ^ pattern, System::Object ^ state);
public static void MapDynamicPageRoute<TTransformer> (this Microsoft.AspNetCore.Routing.IEndpointRouteBuilder endpoints, string pattern, object state) where TTransformer : Microsoft.AspNetCore.Mvc.Routing.DynamicRouteValueTransformer;
public static void MapDynamicPageRoute<TTransformer> (this Microsoft.AspNetCore.Routing.IEndpointRouteBuilder endpoints, string pattern, object? state) where TTransformer : Microsoft.AspNetCore.Mvc.Routing.DynamicRouteValueTransformer;
static member MapDynamicPageRoute : Microsoft.AspNetCore.Routing.IEndpointRouteBuilder * string * obj -> unit (requires 'ransformer :> Microsoft.AspNetCore.Mvc.Routing.DynamicRouteValueTransformer)
<Extension()>
Public Sub MapDynamicPageRoute(Of TTransformer As DynamicRouteValueTransformer) (endpoints As IEndpointRouteBuilder, pattern As String, state As Object)

類型參數

TTransformer

的型別 DynamicRouteValueTransformer

參數

endpoints
IEndpointRouteBuilder

IEndpointRouteBuilder要加入路由的 。

pattern
String

路由的 URL 模式。

state
Object

要提供給 TTransformer 實例的狀態物件。

備註

這個方法允許註冊 RouteEndpoint ,並 DynamicRouteValueTransformer 結合以動態方式使用自訂邏輯來選取頁面。

的實例 TTransformer 將會從相依性插入容器擷取。 在 中 ConfigureServices 向所需的服務存留期註冊 TTransformer

適用於

MapDynamicPageRoute<TTransformer>(IEndpointRouteBuilder, String, Object, Int32)

來源:
RazorPagesEndpointRouteBuilderExtensions.cs

將特製化 RouteEndpoint 新增至 IEndpointRouteBuilder ,其會嘗試使用 所產生的 TTransformer 路由值來選取頁面。

public:
generic <typename TTransformer>
 where TTransformer : Microsoft::AspNetCore::Mvc::Routing::DynamicRouteValueTransformer[System::Runtime::CompilerServices::Extension]
 static void MapDynamicPageRoute(Microsoft::AspNetCore::Routing::IEndpointRouteBuilder ^ endpoints, System::String ^ pattern, System::Object ^ state, int order);
public static void MapDynamicPageRoute<TTransformer> (this Microsoft.AspNetCore.Routing.IEndpointRouteBuilder endpoints, string pattern, object state, int order) where TTransformer : Microsoft.AspNetCore.Mvc.Routing.DynamicRouteValueTransformer;
static member MapDynamicPageRoute : Microsoft.AspNetCore.Routing.IEndpointRouteBuilder * string * obj * int -> unit (requires 'ransformer :> Microsoft.AspNetCore.Mvc.Routing.DynamicRouteValueTransformer)
<Extension()>
Public Sub MapDynamicPageRoute(Of TTransformer As DynamicRouteValueTransformer) (endpoints As IEndpointRouteBuilder, pattern As String, state As Object, order As Integer)

類型參數

TTransformer

的型別 DynamicRouteValueTransformer

參數

endpoints
IEndpointRouteBuilder

IEndpointRouteBuilder要加入路由的 。

pattern
String

路由的 URL 模式。

state
Object

要提供給 TTransformer 實例的狀態物件。

order
Int32

動態路由的比對順序。

備註

這個方法允許註冊 RouteEndpoint ,並 DynamicRouteValueTransformer 結合以動態方式使用自訂邏輯來選取頁面。

的實例 TTransformer 將會從相依性插入容器擷取。 在 中 ConfigureServices 向所需的服務存留期註冊 TTransformer

適用於