LinkGenerator.GetPathByAddress Metoda

Definicja

Przeciążenia

GetPathByAddress<TAddress>(TAddress, RouteValueDictionary, PathString, FragmentString, LinkOptions)

Generuje identyfikator URI ze ścieżką bezwzględną na podstawie podanych wartości.

GetPathByAddress<TAddress>(HttpContext, TAddress, RouteValueDictionary, RouteValueDictionary, Nullable<PathString>, FragmentString, LinkOptions)

Generuje identyfikator URI ze ścieżką bezwzględną na podstawie podanych wartości i HttpContext.

GetPathByAddress<TAddress>(TAddress, RouteValueDictionary, PathString, FragmentString, LinkOptions)

Generuje identyfikator URI ze ścieżką bezwzględną na podstawie podanych wartości.

public abstract string GetPathByAddress<TAddress> (TAddress address, Microsoft.AspNetCore.Routing.RouteValueDictionary values, Microsoft.AspNetCore.Http.PathString pathBase = default, Microsoft.AspNetCore.Http.FragmentString fragment = default, Microsoft.AspNetCore.Routing.LinkOptions options = default);
public abstract string? GetPathByAddress<TAddress> (TAddress address, Microsoft.AspNetCore.Routing.RouteValueDictionary values, Microsoft.AspNetCore.Http.PathString pathBase = default, Microsoft.AspNetCore.Http.FragmentString fragment = default, Microsoft.AspNetCore.Routing.LinkOptions? options = default);
abstract member GetPathByAddress : 'Address * Microsoft.AspNetCore.Routing.RouteValueDictionary * Microsoft.AspNetCore.Http.PathString * Microsoft.AspNetCore.Http.FragmentString * Microsoft.AspNetCore.Routing.LinkOptions -> string
Public MustOverride Function GetPathByAddress(Of TAddress) (address As TAddress, values As RouteValueDictionary, Optional pathBase As PathString = Nothing, Optional fragment As FragmentString = Nothing, Optional options As LinkOptions = Nothing) As String

Parametry typu

TAddress

Typ adresu.

Parametry

address
TAddress

Wartość adresu. Służy do rozpoznawania punktów końcowych.

values
RouteValueDictionary

Wartości trasy. Służy do rozwijania parametrów w szablonie trasy.

pathBase
PathString

Opcjonalna baza ścieżki identyfikatora URI. Prepended do ścieżki w wynikowym identyfikatorze URI.

fragment
FragmentString

Opcjonalny fragment identyfikatora URI. Dołączono do wynikowego identyfikatora URI.

options
LinkOptions

Opcjonalny LinkOptionselement . Ustawienia podanego obiektu zastępują ustawienia pasującymi nazwami z RouteOptions.

Zwraca

Identyfikator URI ze ścieżką bezwzględną lub null.

Dotyczy

GetPathByAddress<TAddress>(HttpContext, TAddress, RouteValueDictionary, RouteValueDictionary, Nullable<PathString>, FragmentString, LinkOptions)

Generuje identyfikator URI ze ścieżką bezwzględną na podstawie podanych wartości i HttpContext.

public abstract string GetPathByAddress<TAddress> (Microsoft.AspNetCore.Http.HttpContext httpContext, TAddress address, Microsoft.AspNetCore.Routing.RouteValueDictionary values, Microsoft.AspNetCore.Routing.RouteValueDictionary ambientValues = default, Microsoft.AspNetCore.Http.PathString? pathBase = default, Microsoft.AspNetCore.Http.FragmentString fragment = default, Microsoft.AspNetCore.Routing.LinkOptions options = default);
public abstract string? GetPathByAddress<TAddress> (Microsoft.AspNetCore.Http.HttpContext httpContext, TAddress address, Microsoft.AspNetCore.Routing.RouteValueDictionary values, Microsoft.AspNetCore.Routing.RouteValueDictionary? ambientValues = default, Microsoft.AspNetCore.Http.PathString? pathBase = default, Microsoft.AspNetCore.Http.FragmentString fragment = default, Microsoft.AspNetCore.Routing.LinkOptions? options = default);
abstract member GetPathByAddress : Microsoft.AspNetCore.Http.HttpContext * 'Address * Microsoft.AspNetCore.Routing.RouteValueDictionary * Microsoft.AspNetCore.Routing.RouteValueDictionary * Nullable<Microsoft.AspNetCore.Http.PathString> * Microsoft.AspNetCore.Http.FragmentString * Microsoft.AspNetCore.Routing.LinkOptions -> string
Public MustOverride Function GetPathByAddress(Of TAddress) (httpContext As HttpContext, address As TAddress, values As RouteValueDictionary, Optional ambientValues As RouteValueDictionary = Nothing, Optional pathBase As Nullable(Of PathString) = Nothing, Optional fragment As FragmentString = Nothing, Optional options As LinkOptions = Nothing) As String

Parametry typu

TAddress

Typ adresu.

Parametry

httpContext
HttpContext

Skojarzone HttpContext z bieżącym żądaniem.

address
TAddress

Wartość adresu. Służy do rozpoznawania punktów końcowych.

values
RouteValueDictionary

Wartości trasy. Służy do rozwijania parametrów w szablonie trasy.

ambientValues
RouteValueDictionary

Wartości skojarzone z bieżącym żądaniem. Opcjonalny.

pathBase
Nullable<PathString>

Opcjonalna baza ścieżki identyfikatora URI. Prepended do ścieżki w wynikowym identyfikatorze URI. Jeśli nie zostanie podana, zostanie użyta PathBase wartość .

fragment
FragmentString

Opcjonalny fragment identyfikatora URI. Dołączono do wynikowego identyfikatora URI.

options
LinkOptions

Opcjonalny LinkOptionselement . Ustawienia podanego obiektu zastępują ustawienia pasującymi nazwami z RouteOptions.

Zwraca

Identyfikator URI ze ścieżką bezwzględną lub null.

Dotyczy